# 🚨 HTML2PDF Deprecated \[UPDATE + ALTERNATIVES\]

**URL:** <https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220>\
**Category:** Community Resources\
**Tags:** pdf\
**Created:** [January 3, 2024, 10:51pm UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220 "2024-01-03T22:51:54Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Loqode](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/loqode/32/50217_2.png) [@Loqode](https://community.glideapps.com/u/Loqode)\
**Post date:** [January 3, 2024, 10:51pm UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/1 "2024-01-03T22:51:54Z")

</div>

# **What’s up Gliders!**

Unfortunately **Replit recently removed their free plan** and automatically unpublished my html2pdf app. This means the original URL is no longer working.

I don’t want to leave you all stranded, so if you want to continue generating HTML based PDF’s for free, you have 3 options:

### **1. Host the code yourself (e.g. on Replit, Render, Netlify, etc):**

```auto
<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>HTML to PDF</title>
  <script src="https://cdn.tailwindcss.com"></script>
  <script>
    function getUrlParameter(name) {
      name = name.replace(/[\[]/, '\\[').replace(/[\]]/, '\\]');
      var regex = new RegExp('[\\?&]' + name + '=([^&#]*)');
      var results = regex.exec(location.search);
      return results === null ? '' : decodeURIComponent(results[1].replace(/\+/g, ' '));
    }

    function loadPdfContent() {
      const pdfContent = getUrlParameter('PDF');
      if (pdfContent) {
        document.getElementById('content').innerHTML = pdfContent;
        setTimeout(function () {
          window.print();
        }, 500); // 1000 milliseconds = 1 second
      }
    }
  </script>
</head>

<body onload="loadPdfContent()">
  <div id="content"></div>
</body>

</html>

```

### **2. Use one of the versions below:**

- **Render** (New Host): `https://pdfwizard.onrender.com/?PDF=HTML`
- **Netlify** (New Host): `https://pdfwizard.netlify.app?PDF=HTML`
- **Replit** (Same Host, Dev Link): `https://81477b6b-70f9-464e-a644-cc79738b18fb-00-2dp7qyh8jyudg.worf.replit.dev/?PDF=HTML`

### **3. Enrol in the Glide Document Masterclass (better methods):**

If you’re looking for more robust, flexible and scalable methods of generating free HTML based PDFs, you can enrol in my Glide Document Masterclass by **[clicking here.](https://bit.ly/loqode-gdm)** Below is the trailer 👇

[![](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/3/a/3a51b756e3fa42d0f35b05edd044e63caa27a058.jpeg "🔥 Glide Course - The Glide Document Masterclass (Official Trailer)") ](https://www.youtube.com/watch?v=gS5nt39V-vI)

---

<div class="post-metadata">

**Author:** ![biha](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/biha/32/84110_2.png) [@biha](https://community.glideapps.com/u/biha)\
**Post date:** [January 4, 2024, 9:14am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/2 "2024-01-04T09:14:21Z")

</div>

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/8/e/8ef796862fb2098b07192c4ff9c09292425e2ae8.png)  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/a/0/a0f7866b22499d73737a01ea57f718b520d33689.png)  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/c/6/c67423debb195dcdf46020ee12d00f3b3df1939a.png)

if i want to use option 1 , it should be done the same way as HTML2PDF? But still cannot. Not sure which part i go wrong

---

<div class="post-metadata">

**Author:** ![Loqode](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/loqode/32/50217_2.png) [@Loqode](https://community.glideapps.com/u/Loqode)\
**Post date:** [January 4, 2024, 9:35am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/3 "2024-01-04T09:35:33Z")

</div>

It’s working for me… For example, copy the links below and open them in a new tab.

`https://pdfwizard.netlify.app/?PDF=%3C!DOCTYPE%20html%3E%20%3Chtml%3E%20%3Chead%3E%20%3Ctitle%3ESimple%20HTML%20Table%3C/title%3E%20%3C/head%3E%20%3Cbody%3E%20%3Ch2%3EMy%20Simple%20Table%3C/h2%3E%20%3Ctable%20border=%221%22%3E%20%3Ctr%3E%20%3Cth%3EFirstname%3C/th%3E%20%3Cth%3ELastname%3C/th%3E%20%3Cth%3EAge%3C/th%3E%20%3C/tr%3E%20%3Ctr%3E%20%3Ctd%3EJohn%3C/td%3E%20%3Ctd%3EDoe%3C/td%3E%20%3Ctd%3E30%3C/td%3E%20%3C/tr%3E%20%3Ctr%3E%20%3Ctd%3EJane%3C/td%3E%20%3Ctd%3ESmith%3C/td%3E%20%3Ctd%3E25%3C/td%3E%20%3C/tr%3E%20%3C/table%3E%20%3C/body%3E%20%3C/html%3E`

_ **OR** (even simpler)_

`https://pdfwizard.netlify.app/?PDF=<h1>Hello</h1>`

Does they work for you?

---

<div class="post-metadata">

**Author:** ![marcgarner](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/marcgarner/32/68656_2.png) [@marcgarner](https://community.glideapps.com/u/marcgarner)\
**Post date:** [January 4, 2024, 11:01am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/4 "2024-01-04T11:01:55Z")

</div>

Hi, tried putting the code directly on our website named the file ‘HTMLtoPDF.php’ but it is returning the error “Request-URI Too Long - The requested URL’s length exceeds the capacity limit for this server.”  
Any ideas? Is it best hosted elsewhere?  
Thanks.

---

<div class="post-metadata">

**Author:** ![Loqode](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/loqode/32/50217_2.png) [@Loqode](https://community.glideapps.com/u/Loqode)\
**Post date:** [January 4, 2024, 11:15am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/5 "2024-01-04T11:15:05Z")

</div>

URLs have a limit on how long they can be (imposed by browsers) so my guess is that you’re trying to convert a massive document? If not, it might be related to the php file? The example above is designed to be a html file (not sure if this matters in your case). Try convert something simple like `<h1>hello</h1>` and see what happens.

---

<div class="post-metadata">

**Author:** ![tuzin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tuzin/32/86077_2.png) [@tuzin](https://community.glideapps.com/u/tuzin)\
**Post date:** [January 4, 2024, 11:15am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/6 "2024-01-04T11:15:45Z")

</div>

Dunno… But thanks for the warning!  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/2/6/26b9a4279dd8d404d35e1c48ec9abfa38adddbe6.png)

---

<div class="post-metadata">

**Author:** ![tuzin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tuzin/32/86077_2.png) [@tuzin](https://community.glideapps.com/u/tuzin)\
**Post date:** [January 4, 2024, 11:16am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/7 "2024-01-04T11:16:47Z")

</div>

I am trying to convert a massive doc indeed, but those docs were working with the old URL

---

<div class="post-metadata">

**Author:** ![Loqode](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/loqode/32/50217_2.png) [@Loqode](https://community.glideapps.com/u/Loqode)\
**Post date:** [January 4, 2024, 11:22am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/8 "2024-01-04T11:22:36Z")

</div>

Interesting that they worked on the old instance but not when you self host… The code is literally the same. Have you tried option 1 with your docs? If both option 1 and 2 don’t work then it’s very odd because literally nothing changed besides the hosting provider, and that’s only affects option 1… If you’re using PHP then I assume you’re running a wordpress website… So your hosting provider or domain registrar may have weird limits imposed. Let me know how you go 👍

---

<div class="post-metadata">

**Author:** ![slscustom.ru](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/slscustom.ru/32/77336_2.png) [@slscustom.ru](https://community.glideapps.com/u/slscustom.ru)\
**Post date:** [January 4, 2024, 11:23am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/9 "2024-01-04T11:23:08Z")

</div>

I also just change a part to pdfwizard.netlify.app but most times isn’t work.  
But before all was ok with this docs.  
This night i have success with this new link, but now it became not work with my docs

---

<div class="post-metadata">

**Author:** ![tuzin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tuzin/32/86077_2.png) [@tuzin](https://community.glideapps.com/u/tuzin)\
**Post date:** [January 4, 2024, 11:28am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/10 "2024-01-04T11:28:45Z")

</div>

I’m trying option 1, I don’t wanna waste time on self-hosing since for me this is just a backup option for only one app 🙂  
It’s just that I assumed it would work if you host the same code with a different provider

---

<div class="post-metadata">

**Author:** ![Loqode](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/loqode/32/50217_2.png) [@Loqode](https://community.glideapps.com/u/Loqode)\
**Post date:** [January 4, 2024, 11:34am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/11 "2024-01-04T11:34:10Z")

</div>

@slscustom.ru @tuzin what happens if you try the link below? It’s the dev link of the old app hosted on replit. If it works, that may be a temporary fix…

`https://81477b6b-70f9-464e-a644-cc79738b18fb-00-2dp7qyh8jyudg.worf.replit.dev/?PDF=hello`

I’m not sure how dev links work though… It may change or spin down after a while, so let me know how you go. This is essentially the exact same app as the original, just with a less pretty URL.

---

<div class="post-metadata">

**Author:** ![tuzin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tuzin/32/86077_2.png) [@tuzin](https://community.glideapps.com/u/tuzin)\
**Post date:** [January 4, 2024, 11:41am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/12 "2024-01-04T11:41:20Z")

</div>

> [@Loqode](#):
>
> 81477b6b-70f9-464e-a644-cc79738b18fb-00-2dp7qyh8jyudg.worf.replit.dev

Yep, it works, thanks!

---

<div class="post-metadata">

**Author:** ![slscustom.ru](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/slscustom.ru/32/77336_2.png) [@slscustom.ru](https://community.glideapps.com/u/slscustom.ru)\
**Post date:** [January 4, 2024, 12:01pm UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/13 "2024-01-04T12:01:57Z")

</div>

Yes, 81477b6b-70f9-464e-a644-cc79738b18fb-00-2dp7qyh8jyudg.worf.replit.dev works exelent, fast, with any docs

---

<div class="post-metadata">

**Author:** ![slscustom.ru](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/slscustom.ru/32/77336_2.png) [@slscustom.ru](https://community.glideapps.com/u/slscustom.ru)\
**Post date:** [January 4, 2024, 12:06pm UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/14 "2024-01-04T12:06:51Z")

</div>

So, we need to find stable and low cost host provider

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [January 4, 2024, 12:26pm UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/15 "2024-01-04T12:26:52Z")

</div>

For what it’s worth, I always use GitHub to host any custom code.

---

<div class="post-metadata">

**Author:** ![martinpstewart](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/martinpstewart/32/59454_2.png) [@martinpstewart](https://community.glideapps.com/u/martinpstewart)\
**Post date:** [January 4, 2024, 12:41pm UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/16 "2024-01-04T12:41:42Z")

</div>

Thanks for this Marco, I have also found the new link is more fussy. 81477b6b-70f9-464e-a644-cc79738b18fb-00-2dp7qyh8jyudg.worf.replit.dev/?PDF works every time for me, and with some very large html too!

---

<div class="post-metadata">

**Author:** ![rvelajr](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/rvelajr/32/63653_2.png) [@rvelajr](https://community.glideapps.com/u/rvelajr)\
**Post date:** [January 4, 2024, 3:44pm UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/17 "2024-01-04T15:44:40Z")

</div>

Woosh! Dodged a bullet here…thnx…I use that HTML2PDF site as well…but 81477b6b-70f9-464e-a644-cc79738b18fb-00-2dp7qyh8jyudg.worf.replit.dev/?PDF …also worked for me…

---

<div class="post-metadata">

**Author:** ![biha](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/biha/32/84110_2.png) [@biha](https://community.glideapps.com/u/biha)\
**Post date:** [January 5, 2024, 12:46am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/18 "2024-01-05T00:46:34Z")

</div>

> ([HTML to PDF (By Loqode)](https://81477b6b-70f9-464e-a644-cc79738b18fb-00-2dp7qyh8jyudg.worf.replit.dev/?PDF=hello))

Wow! This one is work. it can be used?

---

<div class="post-metadata">

**Author:** ![Loqode](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/loqode/32/50217_2.png) [@Loqode](https://community.glideapps.com/u/Loqode)\
**Post date:** [January 5, 2024, 1:00am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/19 "2024-01-05T01:00:23Z")

</div>

It seems to work for now with no issues… Hopefully Replit doesn’t change the URL of this app again! If they do I will update this post with any alternatives I find.

---

<div class="post-metadata">

**Author:** ![biha](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/biha/32/84110_2.png) [@biha](https://community.glideapps.com/u/biha)\
**Post date:** [January 5, 2024, 1:03am UTC](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220/20 "2024-01-05T01:03:06Z")

</div>

Hehhe thank youuu!!!

[Next page](https://community.glideapps.com/t/html2pdf-deprecated-update-alternatives/69220.md?page=2)
