Backlink Script Generator
Copy and paste the script that best matches your website’s structure to automatically create backlinks to your aéPiot page.
1. Universal JavaScript Backlink Script
Insert this script before the </body>
tag on any HTML page. It automatically captures your page title, description (even if no meta description tag exists), and URL.
<script> (function () { const title = encodeURIComponent(document.title); let description = document.querySelector('meta[name="description"]')?.content; if (!description) description = document.querySelector('p')?.textContent?.trim(); if (!description) description = document.querySelector('h1, h2')?.textContent?.trim(); if (!description) description = "No description available"; const encodedDescription = encodeURIComponent(description); const link = encodeURIComponent(window.location.href); const backlinkURL = 'https://aepiot.com/backlink.html?title=' + title + '&description=' + encodedDescription + '&link=' + link; const a = document.createElement('a'); a.href = backlinkURL; a.textContent = 'Get Free Backlink'; a.style.display = 'block'; a.style.margin = '20px 0'; a.target = '_blank'; document.body.appendChild(a); })(); </script>
2. For WordPress Users
Paste this script using a plugin like Insert Headers and Footers or inside a Custom HTML Widget in your footer.
<script> (function () { const title = encodeURIComponent(document.title); let description = document.querySelector('meta[name="description"]')?.content; if (!description) description = document.querySelector('p')?.textContent?.trim(); if (!description) description = document.querySelector('h1, h2')?.textContent?.trim(); if (!description) description = "No description available"; const encodedDescription = encodeURIComponent(description); const link = encodeURIComponent(window.location.href); const backlinkURL = 'https://aepiot.com/backlink.html?title=' + title + '&description=' + encodedDescription + '&link=' + link; const a = document.createElement('a'); a.href = backlinkURL; a.textContent = 'Free WordPress Backlink'; a.target = '_blank'; a.style.display = 'block'; document.body.appendChild(a); })(); </script>
3. For Blogger / Blogspot Users
Use this script in a widget. Go to Layout > Add a Gadget, select HTML/JavaScript, and paste this code inside.
<script> (function () { const title = encodeURIComponent(document.title); let description = document.querySelector('meta[name="description"]')?.content; if (!description) description = document.querySelector('p')?.textContent?.trim(); if (!description) description = document.querySelector('h1, h2')?.textContent?.trim(); if (!description) description = "No description available"; const encodedDescription = encodeURIComponent(description); const link = encodeURIComponent(window.location.href); const backlinkURL = 'https://aepiot.com/backlink.html?title=' + title + '&description=' + encodedDescription + '&link=' + link; const a = document.createElement('a'); a.href = backlinkURL; a.textContent = 'Get Blogger Backlink'; a.target = '_blank'; document.body.appendChild(a); })(); </script>
4. Static HTML Website
For plain HTML files like index.html
, insert the universal script (see section 1) right before the closing </body>
tag. It works without any CMS or plugins.
5. Custom Script Example (Using Page Heading)
If you want to use a custom source for the title (e.g., an <h1>
tag instead of <title>
), use this advanced example:
<script> (function () { const customTitle = encodeURIComponent(document.querySelector('h1')?.textContent?.trim() || document.title); let description = document.querySelector('meta[name="description"]')?.content; if (!description) description = document.querySelector('p')?.textContent?.trim(); if (!description) description = document.querySelector('h2')?.textContent?.trim(); if (!description) description = "No description available"; const encodedDescription = encodeURIComponent(description); const link = encodeURIComponent(window.location.href); const backlinkURL = 'https://aepiot.com/backlink.html?title=' + customTitle + '&description=' + encodedDescription + '&link=' + link; const a = document.createElement('a'); a.href = backlinkURL; a.textContent = 'Custom Backlink'; a.target = '_blank'; document.body.appendChild(a); })(); </script>
6. Free Script Construction
Note: There are several types of scripts presented. Depending on how your website or blog is built, you can create a script to extract the title, link, and description of your page. This way you will have backlinks on the aéPiot platform.