SAML Encoder & Decoder Online

Encode and decode SAML XML as SAMLRequest or SAMLResponse. Beautify SAML XML and check XML syntax. HTTP-POST is XML to Base64. HTTP-Redirect is XML, raw DEFLATE, Base64, then URL encoding. Work stays in your browser.

UTF-8 supported · Processed in your browser
Base64-encoded SAML XML
Message Type
SAML HTTP Binding
Output

What Is SAML Encoding?

SAML (Security Assertion Markup Language) is an XML-based open standard used for exchanging authentication and authorization data between identity providers (IdPs) and service providers (SPs).

SAML encoding converts XML-based SAML messages into a format suitable for transmission over HTTP. Depending on the binding, messages may be Base64-encoded or compressed using DEFLATE before Base64 encoding.

What Is a SAML Request?

A SAML Request is a message sent by a service provider to an identity provider during a Single Sign-On (SSO) process.

An AuthnRequest is a common type of SAML request that asks an identity provider to authenticate a user.

What Is a SAML Response?

A SAML Response is typically sent by an identity provider to a service provider after an authentication request.

It may contain one or more assertions with information about the authenticated user, authentication status, and authorization attributes.

How to Decode a SAML Response Online

  • Copy the Base64-encoded SAML Response.
  • Select SAML Decode mode.
  • Paste the encoded message into the input field.
  • Enable DEFLATE decompression if the message uses HTTP-Redirect binding.
  • Click Decode to view the original SAML XML.
  • Copy or download the decoded XML.

SAML HTTP-POST vs HTTP-Redirect Binding

SAML supports different HTTP bindings for transporting protocol messages.

Feature HTTP-POST HTTP-Redirect
Base64 Yes Yes
DEFLATE No Yes
URL Encoding Form parameter encoding Yes
HTTP Method POST GET
Common use SAML Response AuthnRequest

HTTP-POST typically transports Base64-encoded XML in an HTML form parameter. HTTP-Redirect uses DEFLATE compression, Base64 encoding, and URL encoding.

Common SAML Encoding Errors

Invalid Base64 Data

The input may contain invalid Base64 characters or an incomplete encoded value.

DEFLATE Decompression Failed

The message may not use Raw DEFLATE compression, or the wrong decoding mode may have been selected.

Invalid UTF-8 Data

The decoded bytes may not represent valid UTF-8 text.

Invalid XML

The decoded message may contain malformed XML or incomplete data.

Is SAML Encoding Encryption?

No. SAML encoding is not encryption. Base64 and DEFLATE only change the representation or size of a message. They do not protect its confidentiality.

Sensitive SAML messages should only be handled through trusted systems and secure connections.

Frequently Asked Questions

  • What is a SAML decoder?

    A SAML decoder converts encoded SAML messages back into readable XML so developers can inspect authentication requests and responses.

  • How do I decode a SAML Response?

    Copy the Base64-encoded response, paste it into the decoder, and decode it. For messages encoded with HTTP-POST binding, Base64 decoding is normally sufficient.

  • Why does a SAML Request need DEFLATE compression?

    HTTP-Redirect binding uses DEFLATE compression before Base64 encoding to reduce the size of SAML messages transmitted in URL query parameters.

  • What is the difference between SAMLRequest and SAMLResponse?

    SAMLRequest is commonly used to transmit authentication requests, while SAMLResponse carries the response from an identity provider or another SAML protocol participant.

  • Can I decode a SAML message without DEFLATE?

    Yes. HTTP-POST messages typically require Base64 decoding only. HTTP-Redirect messages require DEFLATE decompression after Base64 decoding.

  • Does SAML encoding protect sensitive information?

    No. Base64 encoding and DEFLATE compression do not encrypt SAML messages.

  • Can this tool validate SAML signatures?

    No. Decoding and XML syntax checking do not verify XML digital signatures or SAML protocol trust.

Is It Safe to Decode SAML Messages Online?

SAML messages can contain usernames, email addresses, identity attributes, and authentication information. This tool processes data in the browser, but users should avoid processing sensitive production messages on shared devices or untrusted websites.

Comments

No comments yet.

Login to comment.