{"library":"sphinxcontrib-napoleon","title":"Sphinx Napoleon Extension","type":"library","description":"Sphinxcontrib-napoleon is a Sphinx extension that acts as a pre-processor, enabling Sphinx to parse and convert both NumPy and Google style docstrings into reStructuredText. This allows developers to write more legible and less verbose docstrings in their Python code. The standalone `sphinxcontrib-napoleon` package is currently at version 0.7, with its last release in 2018. While this package is maintained for compatibility with older Sphinx versions (<=1.2), its core functionality has been integrated directly into Sphinx as `sphinx.ext.napoleon` since Sphinx 1.3, making the `sphinx.ext.napoleon` path the modern standard for newer Sphinx projects.","language":"python","status":"maintenance","last_verified":"Sat May 16","install":{"commands":["pip install sphinxcontrib-napoleon"],"cli":null},"imports":["# conf.py\nextensions = ['sphinxcontrib.napoleon']","# conf.py\nextensions = ['sphinx.ext.napoleon']"],"auth":{"required":false,"env_vars":[]},"links":{"homepage":"https://sphinxcontrib-napoleon.readthedocs.io","github":null,"docs":null,"changelog":null,"pypi":"https://pypi.org/project/sphinxcontrib-napoleon/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null},"quickstart":{"code":"# 1. Install sphinxcontrib-napoleon (if using Sphinx <= 1.2, or for older projects)\n# pip install sphinxcontrib-napoleon\n\n# 2. In your Sphinx project's conf.py file:\nimport os\nimport sys\nsys.path.insert(0, os.path.abspath('.'))\n\n# Add 'sphinx.ext.autodoc' to ensure docstrings are processed\nextensions = [\n    'sphinx.ext.autodoc',\n    'sphinx.ext.napoleon' # Use 'sphinxcontrib.napoleon' for Sphinx <= 1.2\n]\n\n# Optional: Configure napoleon settings (defaults shown)\nnapoleon_google_docstring = True\nnapoleon_numpy_docstring = True\nnapoleon_include_init_with_doc = False\nnapoleon_include_private_with_doc = False\nnapoleon_include_special_with_doc = False\nnapoleon_use_admonition_for_examples = False\nnapoleon_use_admonition_for_notes = False\nnapoleon_use_admonition_for_references = False\nnapoleon_use_ivar = False\nnapoleon_use_param = True\nnapoleon_use_rtype = True\nnapoleon_use_keyword = True\nnapoleon_custom_sections = None\n\n# 3. Generate API documentation (run from your project root or docs directory):\n# sphinx-apidoc -f -o docs/source your_project_module_path\n# make html (or sphinx-build -b html docs/source docs/build/html)","lang":"python","description":"To quickly integrate Napoleon, install the package, then enable it in your Sphinx project's `conf.py` by adding `'sphinx.ext.napoleon'` (or `'sphinxcontrib.napoleon'` for older Sphinx versions) to the `extensions` list. Ensure `sphinx.ext.autodoc` is also enabled. After configuration, use `sphinx-apidoc` to generate RST files from your Python source and then `make html` (or `sphinx-build`) to build the documentation.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":{"tag":null,"tag_description":null,"last_tested":"2026-05-16","installed_version":"0.7","pypi_latest":"0.7","is_stale":false,"summary":{"python_range":"3.10–3.9","success_rate":100,"avg_install_s":1.7,"avg_import_s":null,"wheel_type":"wheel"},"results":[{"runtime":"python:3.10-alpine","python_version":"3.10","os_libc":"alpine (musl)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"18.2M"},{"runtime":"python:3.10-slim","python_version":"3.10","os_libc":"slim (glibc)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":1.6,"import_time_s":null,"mem_mb":null,"disk_size":"19M"},{"runtime":"python:3.11-alpine","python_version":"3.11","os_libc":"alpine (musl)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"20.1M"},{"runtime":"python:3.11-slim","python_version":"3.11","os_libc":"slim (glibc)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":1.7,"import_time_s":null,"mem_mb":null,"disk_size":"21M"},{"runtime":"python:3.12-alpine","python_version":"3.12","os_libc":"alpine (musl)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"12.0M"},{"runtime":"python:3.12-slim","python_version":"3.12","os_libc":"slim (glibc)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":1.6,"import_time_s":null,"mem_mb":null,"disk_size":"12M"},{"runtime":"python:3.13-alpine","python_version":"3.13","os_libc":"alpine (musl)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"11.7M"},{"runtime":"python:3.13-slim","python_version":"3.13","os_libc":"slim (glibc)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":1.6,"import_time_s":null,"mem_mb":null,"disk_size":"12M"},{"runtime":"python:3.9-alpine","python_version":"3.9","os_libc":"alpine (musl)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"17.7M"},{"runtime":"python:3.9-slim","python_version":"3.9","os_libc":"slim (glibc)","variant":"sphinxcontrib-napoleon","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":1.9,"import_time_s":null,"mem_mb":null,"disk_size":"18M"}]}}