Skip to content
DevToolKit

HTTP Basic Auth Generator

Generate RFC 7617 compliant HTTP Basic Authentication headers with full UTF-8 support. Includes code snippets for cURL, JavaScript, Python, and Go.

Resulting Header
Enter credentials to generate...
Was this tool helpful?

How to Use

HTTP Basic Authentication is a simple challenge-response mechanism that allows a client to provide credentials (username and password) to a server. These credentials are combined and encoded into a Base64 string, which is then sent in the Authorization header.

Generating Credentials

  1. Enter Username: Note that per RFC 7617, usernames cannot contain a colon (:).
  2. Enter Password: Passwords can contain any characters, including colons and emojis.
  3. Select Encoding: Choose UTF-8 for modern applications or ISO-8859-1 if you are working with legacy infrastructure.
  4. Copy Header: Use the generated header in your HTTP request or copy one of the provided code snippets.

About This Tool

RFC 7617 and UTF-8 Support

The original Basic Authentication specification (RFC 2617) used the ISO-8859-1 character set. This often led to issues when passwords contained non-English characters or symbols.

The updated RFC 7617 standard officially introduced support for UTF-8. Our generator uses a custom encoding pipeline to ensure that UTF-8 characters are correctly translated into Base64, matching the behavior of modern browsers and server-side libraries.

FAQ

What is HTTP Basic Authentication?
Basic authentication is a simple authentication scheme built into the HTTP protocol. It works by sending a Base64-encoded string of 'username:password' in the 'Authorization' header of a request.
Does this tool support non-English characters?
Yes. While older systems used Latin1 (ISO-8859-1), the modern RFC 7617 standard specifies UTF-8. Our tool supports both, ensuring compatibility with modern APIs and legacy systems.
Can I use a colon in my username or password?
According to RFC 7617, the username cannot contain a colon because it is used as the separator. However, the password can contain any number of colons.
Is my password safe?
Yes. This generator runs 100% locally in your browser. Your credentials are never sent to our servers or stored anywhere. We recommend clearing the tool or refreshing the page after use for extra security.