I successfully tried it for the newer versions of jspdf (version 2.5.1) and autotable (version 3.5.25).

Minimal example:

<!DOCTYPE html>
<html>
    <head>
        <title>jspdf-autotable demo</title>
    </head>
    <body>
        <div>save pdf modal will pop up automatically</div>
    </body>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/jspdf/2.5.1/jspdf.umd.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/jspdf-autotable/3.5.25/jspdf.plugin.autotable.min.js"></script>
    <script>
      const { jsPDF } = window.jspdf;
      const doc= new jsPDF();
      doc.autoTable({
        head: [['Name', 'Email', 'Country']],
        body: [
          ['David', '[email protected]', 'Sweden'],
          ['Castille', '[email protected]', 'Spain'],
        ],
      })
      doc.save("demo.pdf");
    </script>
</html>
Answer from jean-acsas on Stack Overflow
🌐
npm
npmjs.com › package › jspdf-autotable
jspdf-autotable - npm
February 26, 2025 - --></table> autoTable(doc, { html: '#my-table' }) // Or use javascript directly: autoTable(doc, { head: [['Name', 'Email', 'Country']], body: [ ['David', '[email protected]', 'Sweden'], ['Castille', '[email protected]', 'Spain'], // ... ], }) doc.save('table.pdf') You can also use the plugin methods directly on the jsPDF documents:
      » npm install jspdf-autotable
    
Published   Feb 26, 2025
Version   5.0.2
Author   Simon Bengtsson
🌐
GitHub
github.com › simonbengtsson › jsPDF-AutoTable
GitHub - simonbengtsson/jsPDF-AutoTable: jsPDF plugin for generating PDF tables with javascript
--></table> autoTable(doc, { html: '#my-table' }) // Or use javascript directly: autoTable(doc, { head: [['Name', 'Email', 'Country']], body: [ ['David', '[email protected]', 'Sweden'], ['Castille', '[email protected]', 'Spain'], // ... ], }) doc.save('table.pdf') You can also use the plugin methods directly on the jsPDF documents:
Starred by 2.5K users
Forked by 637 users
Languages   TypeScript 89.5% | HTML 7.6% | JavaScript 2.9%
🌐
jsDocs.io
jsdocs.io › package › jspdf-autotable
[email protected] - jsDocs.io
February 26, 2025 - type autoTableInstanceType = (options: UserOptions) => void; type CellHook = (data: CellHookData) => void | boolean; type CellInput = null | string | string[] | number | boolean | CellDef; ... No dependencies. ... To add a badge like this oneto your package's README, use the codes available below. You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/jspdf-autotable.
🌐
GitHub
github.com › JonatanPe › jsPDF-AutoTable
GitHub - JonatanPe/jsPDF-AutoTable
Only the drawCell hook can be used with the native style jspdf style changes such as doc.setLineWidth. If you use the other hooks for changing styles, they will be overridden. autoTableHtmlToJson(tableElem, includeHiddenElements) Use it to generate the javascript objects required for this library from an html table (see from html example).
Starred by 17 users
Forked by 4 users
Languages   TypeScript 81.5% | JavaScript 18.5%
🌐
Phppot
phppot.com › javascript › jspdf-autotable
jsPDF AutoTable example – Table to PDF - Phppot
December 3, 2022 - PDF tables generation from HTML or JavaScript array using jsPDF AutoTables plugin.
🌐
cdnjs
cdnjs.com › home › libraries › jspdf-autotable
jspdf-autotable - Libraries - cdnjs - The #1 free and open source CDN built to make life easier for developers
jspdf-autotable · Generate PDF tables with jsPDF · 2k · GitHub · MIT licensed · Tags: pdf, table, jspdf · Version · 5.0.2 · Loading... Asset Type · All · Loading... https://cdnjs.cloudflare.com/ajax/libs/jspdf-autotable/5.0.2/jspd...
🌐
Simonbengtsson
simonbengtsson.github.io › jsPDF-AutoTable
AutoTable sample
It appears you don't have PDF support in this web browser. Click here to download the PDF
Find elsewhere
🌐
Maven Repository
mvnrepository.com › artifact › org.webjars.bowergithub.simonbengtsson › jspdf-autotable
Maven Repository: org.webjars.bowergithub.simonbengtsson » jspdf-autotable
Home » org.webjars.bowergithub.simonbengtsson » jspdf-autotable · WebJar for jsPDF-AutoTable · Central (3) Web site developed by @frodriguez Powered by: Scala, Play, Spark, Akka and Cassandra · Copyright © 2006-2019 MvnRepository. All rights reserved.
🌐
Snyk
security.snyk.io › snyk vulnerability database › npm
jspdf-autotable vulnerabilities | Snyk
Further analysis of the maintenance status of jspdf-autotable based on released npm versions cadence, the repository activity, and other data points determined that its maintenance is Sustainable.
🌐
Appsmith
community.appsmith.com › tutorial › data-driven-pdf-generator-jspdf-and-autotable
Data-Driven PDF Generator with JSPDF and Autotable | Appsmith Community Portal
October 12, 2024 - In this guide, we'll be using the JSPDF library and the JSPDF-AutoTable plug-in to generate PDFs from customer order data. This method builds a PDF programmatically, one line at a time, as opposed to other methods that use a template or HTML. Using this approach, you can input data from any Appsmith datasource, and transform it with JavaScript to generate a PDF from the live data.
🌐
Rahul Paul
cdns.hashnode.dev › jspdf-autotable-documentation-and-use
jsPDF Autotable Documentation and use
January 25, 2021 - What is jsPDF Autotable? jsPDF Autotable is the standard plugin of jsPDF in order to make Tables in jsPDF Library. With the help of this library you can make awesome tables listed below.
🌐
DevExpress
supportcenter.devexpress.com › ticket › details › t1062815 › exportdatagrid-method-requires-a-autotable-plugin-for-jspdf-object
"exportDataGrid" method requires a autoTable plugin for jsPDF object | DevExpress Support
January 26, 2022 - Hi, I am testing export to pdf and running into runtime error: core.mjs:6495 ERROR Error: The "exportDataGrid" method requires a autoTable p
🌐
Retool
community.retool.com › 💬 app building
How to import and access JS libraries like jsPDF and jsPDF-autotable - 💬 App Building - Retool Forum
September 8, 2023 - Hmm thanx @AnsonHwang I have another query. Can u please ans to it ? I am use jsPDF and jsPDF-autotable libraries in retool How can I use them ? It is not allowing me to import them where I am using these. also If I import them in libraries, then they are not accessible
🌐
UNPKG
unpkg.com › jspdf-autotable
jspdf-autotable
Generate pdf tables with javascript (jsPDF plugin) · simonbengtsson.github.io/jsPDF-AutoTable
🌐
ReversingLabs
secure.software › npm › packages › jspdf-autotable › dependencies › 3.8.2
Dependencies - [email protected] - npm | ReversingLabs Spectra Assure Community
Supply chain risk analysis for jspdf-autotable@3.8.2. Learn more about package security, deployment risks, vulnerabilities, popularity, versions, and more with ReversingLabs.
🌐
CodeSandbox
codesandbox.io › examples › package › jspdf-autotable
jspdf-autotable examples - CodeSandbox
Use this online jspdf-autotable playground to view and fork jspdf-autotable example apps and templates on CodeSandbox.
🌐
GitHub
github.com › simonbengtsson › jsPDF-AutoTable › releases
Releases · simonbengtsson/jsPDF-AutoTable
jsPDF plugin for generating PDF tables with javascript - simonbengtsson/jsPDF-AutoTable
Author   simonbengtsson