RedditapisRedditapis
Listings & Search

Get a Subreddit's Posting Rules

Fetch a subreddit's posting rules by name: each rule's name, description, what it applies to, violation reason and priority, plus Reddit's site rules.

GET/api/reddit/sub/:name/rules$0.002 / call

A subreddit's posting rules (Reddit's /r/<name>/about/rules data): each rule's name, description, what it applies to, violation reason, priority, and creation date, plus Reddit's site-wide rules. Returns a rules list and a site_rules string list.

When to use this

Reach for this to check a community's rules before posting or commenting, what a subreddit forbids, whether a rule applies to posts, comments, or both, and the reason a moderator will cite for a removal. One read.

Path Parameters

ParameterTypeRequiredDescription
namestringYesSubreddit name (no r/ prefix)

A subreddit that does not exist returns 404.

Example

curl -H "Authorization: Bearer $TOKEN" \
  "https://api.redditapis.com/api/reddit/sub/AskReddit/rules"
const response = await fetch(
  "https://api.redditapis.com/api/reddit/sub/AskReddit/rules",
  { headers: { Authorization: "Bearer TOKEN" } }
);
const data = await response.json();
import requests

response = requests.get(
    "https://api.redditapis.com/api/reddit/sub/AskReddit/rules",
    headers={"Authorization": "Bearer TOKEN"},
)

Response Shape

{
  "rules": [
    {
      "name": "Rule 1: Questions must be clear",
      "description": "Posts must be phrased as a genuine, answerable question.",
      "applies_to": "posts",
      "violation_reason": "Unclear or rhetorical question",
      "priority": 0,
      "created_utc": 1201261935,
      "created": "2008-01-25T12:32:15.000Z"
    }
  ],
  "site_rules": [
    "Spam",
    "Personal and confidential information",
    "Threatening, harassing, or inciting violence"
  ]
}

Response Fields

FieldTypeNotes
namestringThe rule's short name / title
descriptionstring | nullThe rule's full description (may be empty / null)
applies_tostringposts | comments | all
violation_reasonstring | nullThe reason shown when the rule is enforced (may be null)
prioritynumber | nullDisplay order Reddit assigns the rule (may be null)
created_utcnumber | nullUnix epoch seconds the rule was created (may be null)
createdstring | nullISO-8601 form of created_utc (may be null)
site_rulesstring[]Reddit's site-wide rules (a list of strings)

Independent third-party API for developers and researchers. Not affiliated with, endorsed by, or sponsored by Reddit, Inc.

On this page