Expand my Community achievements bar.

SOLVED

Broken Link Scan

Avatar

Level 2

Hello,

I am new to AEM and this forum. I am very happy to have found it.

We have a new website implemented via AEM and I have noticed that while we do not have broken links via our production website that we have many text statements that should be linked, and are linked in AEM, but were stripped due to the AEM function to remove bad links from being published.

Is there a way to scan our website or AEM instance for these "broken links" so we can fix them?

Thank you in advance.

1 Accepted Solution

Avatar

Correct answer by
Administrator

Hi

As mentioned by Scott, 

We can use:-

1. The External Link Checker

Link:- https://docs.adobe.com/docs/en/aem/6-2/administer/operations/external-link-checker.html

//An external link checker is provided within CQ. The link checker:

    scans all content pages
    generates a list of all valid and invalid links
    marks invalid links as broken in situ on the individual content pages

2. Linkchecker is a Sling rewriter. Rewriters are strictly associated with the request. They operate on the HTML code generated by the CQ before it's returned to the client. If I understand correctly, you want to look for broken internal links in the whole site and the Linkchecker won't be very useful here.

Consider using Groovy console to crawl over the /content/your_site looking for strings starting with /content. Then use resourceResolver to check if the found path exists. Sample script implementing this algorithm can be found here.

 

Also there exist free online tools to check broken links:-

Link:- http://www.brokenlinkcheck.com/broken-links.php

Link:- www.deadlinkchecker.com

 

I hope this will help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

View solution in original post

5 Replies

Avatar

Level 10

Welcome to the AEM Community. Here you will have access to AEM community members and tons of resources. 

TO check for broken links - there is a tool that is available with AEM named the link checker: 

https://docs.adobe.com/docs/en/aem/6-1/administer/operations/external-link-checker.html

As you are new to AEM - here are some useful pages; 

AEM Community Page

AEM documentation 

AEM HELPX pages

AEM Ask the Community Experts 

Hope these help! 

Avatar

Correct answer by
Administrator

Hi

As mentioned by Scott, 

We can use:-

1. The External Link Checker

Link:- https://docs.adobe.com/docs/en/aem/6-2/administer/operations/external-link-checker.html

//An external link checker is provided within CQ. The link checker:

    scans all content pages
    generates a list of all valid and invalid links
    marks invalid links as broken in situ on the individual content pages

2. Linkchecker is a Sling rewriter. Rewriters are strictly associated with the request. They operate on the HTML code generated by the CQ before it's returned to the client. If I understand correctly, you want to look for broken internal links in the whole site and the Linkchecker won't be very useful here.

Consider using Groovy console to crawl over the /content/your_site looking for strings starting with /content. Then use resourceResolver to check if the found path exists. Sample script implementing this algorithm can be found here.

 

Also there exist free online tools to check broken links:-

Link:- http://www.brokenlinkcheck.com/broken-links.php

Link:- www.deadlinkchecker.com

 

I hope this will help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

Avatar

Level 2

Hello,

Unfortunately this tool is not what I was looking for. What I need is a link checker for ALL links (not just external) that shows me which links are valid and which are not. We did a content migration and many of the internal links have been stripped in production. 

Again I am concerned mostly with links on my domain that are not working.

Thank you for your help.

Jennifer

Avatar

Level 1

Hi ,

Can you help me with internal link checker as well?

The mentioned tool only supports external links.