Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 716427
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T05:17:53+00:00 2026-05-14T05:17:53+00:00

Is there an RFC, official standard, or template for creating a User Agent string?

  • 0

Is there an RFC, official standard, or template for creating a User Agent string? The iphone’s user-agent string seems strange…

Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_1_2 like Mac OS X; en-us) AppleWebKit/528.18 (KHTML, like Gecko) Version/4.0 Mobile/7D11 Safari/528.16

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T05:17:54+00:00Added an answer on May 14, 2026 at 5:17 am

    Note: In June 2022 the IETF (Internet Engineering Task Force) published RFC9110, which obsoleted RFC7231, therefore I’m updating this answer with the new RFC information.

    The User-Agent header is part of the RFC9110, which describes the HTTP Semantics, where is states:

    The "User-Agent" header field contains information about the user agent originating the request, which is often used by servers to help identify the scope of reported interoperability problems, to work around or tailor responses to avoid particular user agent limitations, and for analytics regarding browser or operating system use. A user agent SHOULD send a User-Agent header field in each request unless specifically configured not to do so.

    EBNF Specification

    User-Agent = product *( RWS ( product | comment ) )
    

    Where product is defined as:

    product         = token ["/" product-version]
    product-version = token
    token           = 1*tchar
    tchar           = "!" / "#" / "$" / "%" / "&" / "'" / "*"
                    / "+" / "-" / "." / "^" / "_" / "`" / "|" / "~"
                    / DIGIT / ALPHA
                    ; any VCHAR, except delimiters
    

    And comment is defined as:

    comment     = "(" *( ctext | quoted-pair | comment ) ")"
    ctext       = HTAB | SP | %x21-27 | %x2A-5B | %x5D-7E | obs-text
    quoted-pair = "\" ( HTAB | SP | VCHAR | obs-text )
    obs-text    = %x80-ff
    

    Other rules for reference:

    HTAB  = <ASCII horizontal tab %x09, aka '\t'>
    SP    = <ASCII space, i.e. " ">
    VCHAR = <any visible US-ASCII character>
    DIGIT = <digits from 0 to 9>
    ALPHA = <letters>
    RWS   = 1*( SP | HTAB )
    1*    = <One or more>
    

    Note that this means that product cannot contain spaces, but comments can.


    Examples:

    Here are some valid examples of product strings (with and without product-version strings):

    # Single `product` without product-version:
    Foobar
    Foobar-baz
    
    # Single `product` with product-version:
    Foobar/abc
    Foobar/1.0.0
    Foobar/2021.44.30.15-b917dc
    

    Here are some valid examples of comment strings; note how all strings are enclosed in matched parentheses ( ):

    # This was the default `comment` used by Internet Explorer 11:
    (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0)
    
    # You can put almost any text inside a comment:
    (Why are you looking at HTTP headers? Go outside, find love, do some good in the world)
    
    # Note that `comment` strings can also be nested, provided their delimiting parentheses are matched, for example:
    (Outer comment (Inner comment))
    

    As a User-Agent header’s value is comprised of arbitrary product and comment strings, these are all valid User-Agent headers:

    User-Agent: Foobar
    User-Agent: Foobar/2021.44.30.15-b917dc
    User-Agent: MyProduct Foobar/2021.44.30.15-b917dc
    User-Agent: Tsom/OfraHaza (Life is short and love is always over in the morning) AnotherProduct
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This seems strange to me but I am sure there is an explanation If
There is a standard two-pass algorithm mentioned in RFC 1942: http://www.ietf.org/rfc/rfc1942.txt however I haven't
I have a Java module that receives the User-Agent string from an end user's
I was wondering - is there a standard (like a RFC) for the .sch
I've read through RFC 2617 and can't find there or anywhere else what the
Is there a plan or existing implementation of RFC 5054 in any of the
Is there some information source or technical draft (something like RFC for networking) describing
The RFC seems to suggest that the client should permanently cache the response: http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
Is there any official way to allow a CSV formatted file to allow comments,
Does an official URN for the MIME type exist? Mozilla Firefox and other applications

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.