Online Forum To Support Coders With Technical Assistance - Read Write Execute

Htaccess – flags list

Ankit Agrawal
Ankit Agrawal
Published on March 12, 2020 · 1 min read

Htaccess(.htaccess) file is configuration file on server. It used to alter configuration of Apache server. Flags are added after the rule to instruct server how to execute the rule.

Flags list

  • C    = chained with next rule
  • CO = cookie (set specified cookie)
  • E    = var:value (set environment variable var to value)
  • F    = (forbidden – sends a 403 header to the user)
  • G    = gone (no longer exists)
  • H   = handler (set handler)
  • L    = (last – stop processing rules)
  • N   = next (continue processing rules)
  • NC = case insensitive
  • NE  =do not escape special URL characters in output
  • NS  = ignore this rule if the request is a subrequest
  • P  = proxy (apache should grab the remote content specified in the substitution section and return it)
  • PT  = pass through (use when processing URLs with additional handlers, e.g., mod_alias)
  • R = temporary redirect to new URL
  • R=301 (permanent redirect to new URL)
  • QSA (append query string from request to substituted URL)
  • S=x (skip next x rules)
  • T=mime-type (force specified mime type)
Was this article helpful?
Ankit Agrawal

Ankit Agrawal

Author & Senior Engineer at CodeExecute

Writing practical engineering guides, debugging real-world bottlenecks, and creating free tools for developer productivity.

← Previous Article What is offscreen images Next Article → How to check that image exists on remote url