Skip to main content

Getting your documentation just right is important, and Redoc comes with many configuration options to help you succeed in that mission. Each deployment type has documentation on how to configure options for that type of Redoc project. This page lists all the options you can use with Redoc. Versions: 2.x
Client-side configurationUsing Redoc as a standalone (HTML or React) tool, these options must be presented in kebab case. For example:
  • scrollYOffset becomes scroll-y-offset
  • expandResponses becomes expand-responses

Functional settings

Core Settings

OptionDescriptionDefault
disableSearchDisables search indexing and hides search boxfalse
minCharacterLengthToInitSearchMinimum characters for search3
hideDownloadButtonsHides the download buttonfalse
hideLoadingHides loading animationfalse

Theme settings

You can customize the look and feel of your documentation with these theme options:
theme:
  # Typography
  typography:
    fontSize: '14px'
    fontFamily: 'Roboto, sans-serif'
    headings:
      fontFamily: 'Montserrat, sans-serif'
      fontWeight: '400'
    
  # Colors and Layout
  colors:
    primary:
      main: '#32329f'
  
  # Sidebar Configuration
  sidebar:
    width: '260px'
    backgroundColor: '#fafafa'
    textColor: '#333333'
Check our theme customization guide for detailed examples and best practices.

Additional customization

Security Definition location

You can inject the Security Definitions widget into any place in your definition description. For more information, refer to Security definitions injection.

OpenAPI specification extensions

Redoc supports several custom OpenAPI extensions to enhance your documentation:
  • x-logo - Specify API logo
  • x-traitTag - Handle common patterns like Pagination
  • x-codeSamples - Add operation code samples
  • x-examples - Specify JSON request examples
  • x-nullable - Mark schema parameters as nullable
  • x-displayName - Set friendly menu category names
  • x-tagGroups - Group sidebar menu tags
  • x-servers - Specify different API servers