diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt
index fbcd84ba..cbcbf7bd 100644
--- a/doc/CMakeLists.txt
+++ b/doc/CMakeLists.txt
@@ -197,6 +197,11 @@ add_docbook(dbus-tutorial SOURCE dbus-tutorial.xml FORMATS html)
#
# handle html index file
#
+if(DBUS_ENABLE_DOXYGEN_DOCS)
+ set(DBUS_APIDOC_LINK "libdbus API Documentation")
+else()
+ set(DBUS_APIDOC_LINK "")
+endif()
configure_file(index.html.in ${CMAKE_CURRENT_BINARY_DIR}/index.html)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/index.html DESTINATION ${CMAKE_INSTALL_DATADIR}/doc/dbus)
diff --git a/doc/index.html.in b/doc/index.html.in
index feca9fc8..eb61d061 100644
--- a/doc/index.html.in
+++ b/doc/index.html.in
@@ -36,7 +36,7 @@ application manuals
D-Bus Test Plan
-libdbus API Documentation
+@DBUS_APIDOC_LINK@