dotCMS provides a workflow action that allows to check the content before saving it, for any external link inconsistencies.
First click on the Content tab, and click on “Add New Content”. In the Edit Content screen you will find the workflow action: “Check External Links” under “Actions”. If you don't have the action contact your Administrator to Configure the Check External Links action in the Workflow Scheme.
Fill out the fields, making sure you create a broken link in the WYSIWYG field: Body. To create a new link from the WYSIWYG highlight any text in the Body field and click on the “link” icon and enter the following information and click on “Insert”.
Link URL: http://www.dotcms.aaaa/
Title: This url doesn’t exist
When you're done adding content to each field click on “Check External Links” and a dialog will open showing the broken links found. You will not be able to save the content until the broken links have been fixed. Once they are fixed, click on Save and return to the Content Search manager screen.