diff --git a/docs/source/openapi.rst b/docs/source/openapi.rst
index 00a5483..0c387b8 100644
--- a/docs/source/openapi.rst
+++ b/docs/source/openapi.rst
@@ -21,8 +21,8 @@ The API is accessible at the ``/openapi`` endpoint, providing a Swagger-based we
the pygeoapi demo OpenAPI/Swagger endpoint at https://demo.pygeoapi.io/master/openapi
-Using OpenAPI
--------------
+Using OpenAPI via Swagger
+-------------------------
Accessing the Swagger webpage we have the following structure:
@@ -62,6 +62,13 @@ This identifier can be used to obtain a specific item from the dataset using the
.. image:: /_static/openapi_get_item_id2.png
+Using OpenAPI via ReDoc
+-----------------------
+
+pygeoapi also supports OpenAPI document rendering via `ReDoc `_.
+
+ReDoc rendering is accessible at the same ``/openapi`` endpoint, adding ``ui=redoc`` to the request URL.
+
Summary
-------
diff --git a/pygeoapi/api.py b/pygeoapi/api.py
index 4d99282..af77278 100644
--- a/pygeoapi/api.py
+++ b/pygeoapi/api.py
@@ -629,13 +629,18 @@ class API:
return self.get_format_exception(request)
headers = request.get_response_headers()
+
if request.format == F_HTML:
+ template = 'openapi/swagger.html'
+ if request._args.get('ui') == 'redoc':
+ template = 'openapi/redoc.html'
+
path = '/'.join([self.config['server']['url'].rstrip('/'),
'openapi'])
data = {
'openapi-document-path': path
}
- content = render_j2_template(self.config, 'openapi.html', data,
+ content = render_j2_template(self.config, template, data,
request.locale)
return headers, 200, content
diff --git a/pygeoapi/templates/landing_page.html b/pygeoapi/templates/landing_page.html
index 417a62e..caca4a8 100644
--- a/pygeoapi/templates/landing_page.html
+++ b/pygeoapi/templates/landing_page.html
@@ -68,7 +68,7 @@