Broken Links Detected In Documentation: Analysis And Fixes
Maintaining a healthy and up-to-date documentation ecosystem is crucial for any project. Broken links can lead to a frustrating user experience, hinder understanding, and ultimately detract from the value of your documentation. In this article, we'll dive into a comprehensive analysis of broken links detected in documentation, providing insights into the types of errors, their locations, and actionable steps to resolve them. By addressing these issues promptly, you can ensure your documentation remains a reliable and valuable resource for your users.
Understanding the Impact of Broken Links
Before we delve into the specifics of the detected broken links, let's take a moment to understand why they matter. Broken links, also known as link rot, can have several negative consequences:
- User Frustration: Imagine a user diligently following a guide, only to encounter a dead end when clicking a link. This can lead to frustration and a negative perception of your project.
- Information Gaps: Broken links can create gaps in the information you're providing, making it difficult for users to fully understand a concept or complete a task.
- SEO Impact: Search engines penalize websites with broken links, as they indicate neglect and a poor user experience. This can negatively impact your search engine rankings.
- Loss of Credibility: A documentation set riddled with broken links can erode trust in your project and its maintainers.
Therefore, regularly monitoring and fixing broken links is an essential part of maintaining high-quality documentation. Addressing these issues ensures a smoother, more informative experience for your users, and it also reflects a commitment to excellence in your project's resources.
Overview of Broken Link Analysis
Our analysis involved scanning the documentation to identify links that are no longer functioning correctly. This includes links that:
- Return an error (e.g., 404 Not Found).
- Redirect to an unexpected page.
- Time out due to network issues.
The following table summarizes the results of our broken link detection process:
| Status | Count |
|---|---|
| 🔍 Total | 1397 |
| ✅ Successful | 1135 |
| ⏳ Timeouts | 0 |
| 🔀 Redirected | 55 |
| 👻 Excluded | 205 |
| ❓ Unknown | 0 |
| 🚫 Errors | 2 |
| ⛔ Unsupported | 0 |
From this overview, we can see that the vast majority of links (1135 out of 1397) are functioning correctly. However, there are 2 links resulting in errors and 55 links that redirect, which require further investigation.
Detailed Breakdown of Errors
Let's examine the specific errors encountered during the link analysis.
Errors in demos/demo-debugging-assistant.prompt.md
[ERROR] <https://jvns.ca/blog/2022/12/08/a-debugging-manifesto/>| Network error: Connection failed. Check network connectivity and firewall settings
This error indicates a network issue preventing access to the linked resource. It could be a temporary problem with the server hosting the blog post or an issue with network connectivity on the client-side.
Errors in src/tools/prompt/debugging-assistant-prompt-builder.ts
[ERROR] <https://jvns.ca/blog/2022/12/08/a-debugging-manifesto/>| Error (cached)
This error suggests a cached failure, possibly related to a previous attempt to access the link. It could indicate a persistent issue with the linked resource or a configuration problem within the system.
The recurring error for https://jvns.ca/blog/2022/12/08/a-debugging-manifesto/ warrants immediate attention. It's essential to verify if the linked resource is permanently unavailable or if the issue is temporary. If the link is indeed broken, it should be replaced with an updated link or removed altogether.
Analysis of Redirects
While redirects don't necessarily indicate broken links, they can still impact the user experience and SEO. Too many redirects or redirects to irrelevant pages can be detrimental. It's crucial to review redirects to ensure they point to the intended content.
Redirects in .github/CODE_OF_CONDUCT.md
[200] <https://www.contributor-covenant.org/version/2/1/code_of_conduct.html>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://www.contributor-covenant.org/version/2/1/code_of_conduct.html-->https://www.contributor-covenant.org/version/2/1/code_of_conduct/
This redirect is a simple URL normalization, adding a trailing slash. While functional, it's best practice to update the link to the final URL to avoid unnecessary redirects.
Redirects in demos/demo-clean-code-score.md
[200] <https://docs.sonarqube.org/latest/user-guide/metric-definitions/>| Redirect: Followed 2 redirects resolving to the final status of: OK. Redirects:https://docs.sonarqube.org/latest/user-guide/metric-definitions/-->https://docs.sonarsource.com/sonarqube/latest/user-guide/metric-definitions/-->https://docs.sonarsource.com/sonarqube-server/user-guide/code-metrics/metrics-definition
This redirect chain indicates a significant change in the URL structure of the SonarQube documentation. The link should be updated to the final destination to improve efficiency and user experience.
Redirects in demos/demo-code-analysis.domain-neutral.prompt.md
[200] <https://www.iso.org/iso-31000-risk-management.html>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://www.iso.org/iso-31000-risk-management.html-->https://www.iso.org/standard/65694.html
This redirect points to a new URL for the ISO 31000 standard. The link should be updated to the new URL for clarity and direct access.
Redirects in demos/demo-code-analysis.guidelines.md
[200] <https://www.anthropic.com/news/prompt-caching>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://www.anthropic.com/news/prompt-caching-->https://claude.com/blog/prompt-caching
This redirect reflects a change in the Anthropic blog's domain. The link should be updated to https://claude.com/blog/prompt-caching.
Redirects in demos/demo-code-analysis.hygiene.md
[200] <https://graphite.dev/guides/refactoring-legacy-code-best-practices-techniques>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://graphite.dev/guides/refactoring-legacy-code-best-practices-techniques-->https://graphite.com/guides/refactoring-legacy-code-best-practices-techniques
This redirect indicates a domain change from graphite.dev to graphite.com. Update the link accordingly.
Redirects in demos/demo-code-analysis.memory.md
[200] <https://docs.anthropic.com/en/docs/build-with-claude/prompt-caching>| Redirect: Followed 2 redirects resolving to the final status of: OK. Redirects:https://docs.anthropic.com/en/docs/build-with-claude/prompt-caching-->https://docs.claude.com/en/docs/build-with-claude/prompt-caching-->https://platform.claude.com/docs/en/build-with-claude/prompt-caching[200] <https://www.anthropic.com/news/prompt-caching>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://www.anthropic.com/news/prompt-caching-->https://claude.com/blog/prompt-caching
The first redirect chain shows multiple changes in the documentation URL structure. The link should be updated to the final destination, https://platform.claude.com/docs/en/build-with-claude/prompt-caching. The second redirect, as seen before, points to the new Anthropic blog domain.
Redirects in demos/demo-code-analysis.model-compat.md
[200] <https://docs.anthropic.com/en/docs/about-claude/models>| Redirect: Followed 3 redirects resolving to the final status of: OK. Redirects:https://docs.anthropic.com/en/docs/about-claude/models-->https://docs.claude.com/en/docs/about-claude/models-->https://platform.claude.com/docs/en/about-claude/models-->https://platform.claude.com/docs/en/about-claude/models/overview
This extensive redirect chain suggests a significant reorganization of the Anthropic documentation. Update the link to https://platform.claude.com/docs/en/about-claude/models/overview.
Redirects in demos/demo-code-analysis.validator.md
[200] <https://graphite.dev/guides/refactoring-legacy-code-best-practices-techniques>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://graphite.dev/guides/refactoring-legacy-code-best-practices-techniques-->https://graphite.com/guides/refactoring-legacy-code-best-practices-techniques[200] <https://www.anthropic.com/news/prompt-caching>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://www.anthropic.com/news/prompt-caching-->https://claude.com/blog/prompt-caching
These redirects, again, reflect the domain change for Graphite and the Anthropic blog.
Redirects in demos/demo-coverage-enhancement.md
[200] <https://docs.github.com/en/actions/automating-builds-and-tests/about-continuous-integration>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://docs.github.com/en/actions/automating-builds-and-tests/about-continuous-integration-->https://docs.github.com/en/actions/get-started/continuous-integration
This redirect points to a new location for the GitHub Actions continuous integration documentation. Update the link to https://docs.github.com/en/actions/get-started/continuous-integration.
Redirects in demos/demo-dependency-audit.md
[200] <https://www.typescriptlang.org/tsconfig>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://www.typescriptlang.org/tsconfig-->https://www.typescriptlang.org/tsconfig/
Similar to the earlier .github/CODE_OF_CONDUCT.md redirect, this is a URL normalization with a trailing slash. Update the link to include the trailing slash.
Redirects in demos/demo-enterprise-architect.prompt.md
[200] <https://csrc.nist.gov/publications/detail/sp/800-207/final>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://csrc.nist.gov/publications/detail/sp/800-207/final-->https://csrc.nist.gov/pubs/sp/800/207/final[200] <https://learn.microsoft.com/azure/cloud-adoption-framework/>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://learn.microsoft.com/azure/cloud-adoption-framework/-->https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/[200] <https://pubs.opengroup.org/architecture/o-aa-standard/>| Redirect: Followed 2 redirects resolving to the final status of: OK. Redirects:https://pubs.opengroup.org/architecture/o-aa-standard/-->https://identity.opengroup.org/oauth2/authorize?response_type=code&scope=openid&client_id=J1MVMsuCgZIuKgLLpn596BZ4Kf0a&state=obsHAsn03SjBxzAzOLRNYWWvZIc&redirect_uri=https%3A%2F%2Fpubs.opengroup.org%2Fsso_redirect_uri&nonce=Hl6_KlaKBKLKwKH4UX_xF22vRD6K9D5OAcdHEdN5DHo-->https://identity.opengroup.org/authenticationendpoint/login.do?client_id=J1MVMsuCgZIuKgLLpn596BZ4Kf0a&commonAuthCallerPath=%2Foauth2%2Fauthorize&forceAuth=false&nonce=Hl6_KlaKBKLKwKH4UX_xF22vRD6K9D5OAcdHEdN5DHo&passiveAuth=false&redirect_uri=https%3A%2F%2Fpubs.opengroup.org%2Fsso_redirect_uri&response_type=code&scope=openid&state=obsHAsn03SjBxzAzOLRNYWWvZIc&sessionDataKey=a6fe0c0e-5e31-4dd4-9d18-a88894fa52ab&relyingParty=J1MVMsuCgZIuKgLLpn596BZ4Kf0a&type=oidc&sp=Pubs&isSaaSApp=false&authenticators=BasicAuthenticator%3ALOCAL
The first two redirects indicate changes in the URL structure for NIST and Microsoft documentation, respectively. The third redirect is more complex, involving an authentication flow. It might be preferable to link to a more stable, user-friendly page on the Open Group Architecture Framework (TOGAF) website if available.
Redirects in demos/demo-gap-analysis.md
[200] <https://www.mindtools.com/pages/article/gap-analysis.htm>| Redirect: Followed 2 redirects resolving to the final status of: OK. Redirects:https://www.mindtools.com/pages/article/gap-analysis.htm-->https://members.mindtools.com/pages/article/gap-analysis.htm-->https://members.mindtools.com/afv9hac/gap-analysis
This redirect chain indicates a move to a member-specific page on MindTools. Consider whether this is the most appropriate link for your audience or if a different resource should be used.
Redirects in demos/demo-l9-engineer.prompt.md
[200] <http://highscalability.com/>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:http://highscalability.com/-->https://highscalability.com/[200] <https://www.devops-research.com/research.html>| Redirect: Followed 2 redirects resolving to the final status of: OK. Redirects:https://www.devops-research.com/research.html-->https://dora.dev/research.html-->https://dora.dev/
The first redirect is a simple HTTP to HTTPS upgrade. The second redirect indicates a domain change for DevOps Research and Assessment (DORA). Update the links accordingly.
Redirects in demos/demo-mode-switcher.md
[200] <https://code.visualstudio.com/docs/editor/editingevolved>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://code.visualstudio.com/docs/editor/editingevolved-->https://code.visualstudio.com/docs/editing/editingevolved[200] <https://www.anthropic.com/index/prompting-long-context>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://www.anthropic.com/index/prompting-long-context-->https://www.anthropic.com/news/prompting-long-context
The first redirect shows a change in the Visual Studio Code documentation structure. The second, again, is the Anthropic blog domain change.
Redirects in demos/demo-project-onboarding.md
[200] <https://code.visualstudio.com/docs/editor/editingevolved>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://code.visualstudio.com/docs/editor/editingevolved-->https://code.visualstudio.com/docs/editing/editingevolved
Another instance of the Visual Studio Code documentation change.
Redirects in demos/demo-semantic-analysis.md
[200] <https://code.visualstudio.com/docs/editor/editingevolved>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://code.visualstudio.com/docs/editor/editingevolved-->https://code.visualstudio.com/docs/editing/editingevolved
Yet another instance of the Visual Studio Code documentation change.
Redirects in docs/.frames-static/IMPLEMENTATION_GUIDE.md
[200] <https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-reduced-motion>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-reduced-motion-->https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@media/prefers-reduced-motion[200] <https://primer.style/foundations/color>| Redirect: Followed 2 redirects resolving to the final status of: OK. Redirects:https://primer.style/foundations/color-->https://primer.style/foundations/color/-->https://primer.style/product/primitives/color/
The first redirect shows a restructuring of the MDN Web Docs. The second indicates changes in the Primer style guide's URL structure.
Redirects in docs/.frames-static/README.md
[200] <https://primer.style/foundations/color>| Redirect: Followed 2 redirects resolving to the final status of: OK. Redirects:https://primer.style/foundations/color-->https://primer.style/foundations/color/-->https://primer.style/product/primitives/color/[200] <https://primer.style/foundations/icons>| Redirect: Followed 2 redirects resolving to the final status of: OK. Redirects:https://primer.style/foundations/icons-->https://primer.style/foundations/icons/-->https://primer.style/octicons/
These redirects reflect changes in the Primer style guide's URL structure, including a move from the foundations/icons path to octicons.
Redirects in docs/development/visual-design-reference.md
[200] <https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-reduced-motion>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-reduced-motion-->https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@media/prefers-reduced-motion[200] <https://web.dev/animations/>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://web.dev/animations/-->https://web.dev/explore/animations[200] <https://www.w3.org/WAI/WCAG21/quickref/>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://www.w3.org/WAI/WCAG21/quickref/-->https://www.w3.org/WAI/WCAG22/quickref/?versions=2.1
These redirects indicate updates to documentation on MDN Web Docs, web.dev, and the W3C Web Accessibility Initiative (WAI) quick reference.
Redirects in docs/tips/agent-relative-calls.md
[200] <https://modelcontextprotocol.io/introduction>| Redirect: Followed 1 redirect resolving to the final status of: OK. Redirects:https://modelcontextprotocol.io/introduction-->https://modelcontextprotocol.io/docs/getting-started/intro
This redirect points to the