r/quarto • • Mar 22 '26

Render quarto document in HTML and pdf

1 Upvotes

Bonjour, j'ai codé un petite page html pour un projet et je veux également le render en tant que pdf, cependant dans mon code se trouve une section dans laquelle des nombres aléatoires apparaissent. Lorsque je clique sur Render j'ai donc ma page html et à l'interieur de cette page apparait une icone pour télécharger en pdf, parfait me diriez vous, cependant lorsque je clique sur le téléchargement, un nouveau tirage de nombre aléatoires apparaissent, les numéros apparaissant dans le pdf ne sont donc pas les même que dans la page html, si vous pouvez m'aidez ça serait top.

De plus lorsque je télécharge le pdf, le texte occupe seulement la moitié de la page (voir image) et le code dépasse du bloc, savez vous comment résoudre cela ?

Je suis un débutant sur quarto, en espérant que vous pourrez m'aider


r/quarto • • Apr 13 '26

Strange problem with preview...

1 Upvotes

I've been using quarto for a while, and have started having a strange problem that I can't figure out how to fix. For some reason, links - in preview only - keep redirecting me back to whatever page I'm on. If I use the static files in _site it works fine, and it works fine on my deployed site. However, here are the log messages in preview:

Browse at http://localhost:6256/
Listening on http://127.0.0.1:6256/
Opening in existing browser session.
GET: /
GET: /about.html
GET: /
GET: /resources.html
GET: /
GET: /
GET: /resources.html
GET: /

I clicked on my "about" link, and it shows that but then immediately does a second "GET" for the home page and that's all I see in the browser. It does this when I click on links in the header, but I can type out the URL (manually enter the "about.html") and it works fine. If I click on links further down the page, not in the header, it works fine. If I manually enter about.html to go to the about page, and then click on the "resources" link in the header, it redirects me back to the about page (or whatever page I'm currently on).

I can temporarily fix this: If I delete all of _site and then start preview, it's fine. But if I shut that down and restart again, without deleting _site, things are back to not working.

I've tried removing all extensions, removing .quarto, ... nothing seems to help. Any ideas?


r/quarto • • Jun 30 '26

An iOS app that renders Quarto (.qmd) and Markdown (.md) files on iPhone/iPad

2 Upvotes

If you just want to open a raw .qmd or .md file on your phone, iOS shows plain text. I made a small viewer that renders the Markdown so you can read the prose, code, and math on mobile.

Md Preview:

• Renders Markdown incl. .qmd and .rmd (plus .md / .markdown / .mdx)

• Code blocks with syntax highlighting

• LaTeX math rendering and Mermaid diagrams

• Opens from Files / Share Sheet; on-device, nothing uploaded

On the App Store: https://apps.apple.com/app/id6760341080

Info: https://markdown.cybergame.ai/

To be clear it doesn't render/execute Quarto — it just renders the Markdown source of a .qmd so you can read it on a phone. Useful, or do you only ever read the rendered HTML/PDF?


r/quarto • • Mar 21 '25

Quarto & LaTeX: Using Both Numbered and Starred Footnotes in the Same Document

2 Upvotes

I'm working with Quarto and LaTeX to format footnotes in my document. Numbered footnotes for citations are working correctly and restart at the beginning of each section. However, I also need to add explanatory footnotes using stars (*, **, ***) that reset on each page. The problem is that Quarto/LaTeX applies the same numbering system to both citation footnotes and explanatory notes, causing conflicts.

How can I implement both systems simultaneously—numbered footnotes restarting in each section and starred footnotes resetting on each page—within a Quarto-based LaTeX template?


r/quarto • • Jul 21 '25

Changing indent and spacing for appendices in a book document

2 Upvotes

Hi all!

I am using Quarto for my dissertation, and I have it set up as a book outputting to a PDF.

I have the following in my .yml specifying some of the book-wide settings I want:

format:
  pdf:
    documentclass: book
    pdf-engine: lualatex
    classoption: ["oneside", "open=any"]
    margin-left: "1.5in"
    margin-right: "1in"
    margin-top: "1in"
    margin-bottom: "1in"
    linestretch: 2
    template-partials: 
      - "tex/before-body.tex" 
      - "tex/_titlepage.tex" 
      - "tex/toc.tex" 
    include-in-header: 
      - text: | 
          \raggedright
          \usepackage{indentfirst}
          \setlength{\parindent}{0.5in}
          \setlength{\parskip}{0in}
          \usepackage{fvextra}
          \DefineVerbatimEnvironment{Highlighting}{Verbatim}{breaklines,commandchars=\\\{\}}
          \usepackage{setspace}
          \doublespacing
          \pagenumbering{gobble} 
          \usepackage{sectsty}
          \usepackage{titlesec}
          \usepackage{fontspec}
          
          \titleformat{\chapter}[display]
          {\normalfont\centering}{}{0pt}{\fontsize{12}{12}\selectfont}
          \titlespacing*{\chapter}{0pt}{0pt}{12pt}
          
          \titleformat{\section}[hang]
          {\normalfont}{\thesection}{1ex}{\fontsize{12}{12}\selectfont}
          \titlespacing*{\section}{0pt}{12pt}{0pt}
          
          \titleformat{\subsection}[hang]
          {\normalfont\centering}{\thesubsection}{3ex}{\fontsize{12}{12}\selectfont}
          \titlespacing*{\subsection}{0pt}{0pt}{0pt}

          \titleformat{\subsubsection}[hang]
          {\normalfont\centering}{\thesubsubsection}{3ex}{\fontsize{12}{12}\selectfont}
          \titlespacing*{\subsection}{0pt}{0pt}{0pt}

          \sectionfont{\fontsize{12}{12}\selectfont\centering}
          \subsectionfont{\fontsize{12}{12}\selectfont\centering}
          
          \usepackage{enumitem}
          \usepackage{CharisSIL}
          \usepackage{tipa}
    dev: cairo_pdf      
    toc: true
    toc-depth: 3
    lot: true
    lof: true
    # I changed
    number-sections: TRUE
    indent: FALSE

However, I have some appendices that are no longer in paragraph form. They're lists of instructions, images/tables, and other forms where the indentation and line spacing spacing are causing it to look really strange. What's my best way to alter those settings for each appendix files .qmd? My goal is to remove the leading indentation on a new line and to go down to 1.0 spacing for selected appendices. Thanks for any guidance.


r/quarto • • Jan 04 '25

two Quarto blog questions

6 Upvotes

I've switched to quarto and GitHub hosting. I have built a professional site with the plan now to build a blog that links from it. I've built a stand-alone blog sandbox, so I think I know the basics. However, I have two housekeeping and efficiency questions.

  1. My blog posts will be collections of common themes. Hundreds of individual folders inside of posts/ will be a mess for me to keep track of. Of course, they individual posts will be tagged for rendering later, but that doesn't help my .qmd organization. Any tips? Is there any reason I can't create subfolders for the primary posts/ directory?

  2. The process of creating a single post seems to require a lot of steps. Are there any scripts or shortcuts to go from "idea" to a post shell that's ready for writing content to an empty file? Again, tips would be welcome. I would have thought that RStudio or VSCode (what I use) would have had something built-in to their quarto extensions.

  3. I lied. I have a third question...I would probably name each post's directory with the ISO date and an identifier, but any tips on an organized naming scheme would be helpful also.

  4. Now I really cannot be trusted. Must I repeat reference.bib files inside of each post's directory, or can I create cite references in a post to a site-wide, global references.bib file?

Now I'rm really done. thanks for reading a complicated set of questions.


r/quarto • • Dec 22 '24

quarto website: updated to 1.6 version and my descriptions disappeared from the main blog listing pages

5 Upvotes

i've been building a simple blog website in quarto. the main listing pages used to display document titles, an image, and the first chunk of page content. looked pretty good.

i noticed there was a quarto update so i installed to version 1.6. now my blog list pages no longer display the first chunk of content. only see title and image.

i've been poring over the docs for hours now and can't seem to find a setting to fix this. i'm intentionally setting the max-description-length in the YAML but that doesn't help.

any other ideas on how to bring that back?


r/quarto • • Feb 12 '25

filtering labels with cross-references. Documentation (or help)

4 Upvotes

I failed to write a lua filter achieving some simple task, it seems the way Quarto is passing equation labels to pandoc has changed in the last versions. I was wondering if there is any recent documentation about it, or if someone can help me.

I am given a text with labelled equations, like in this example from Quarto website

```

Black-Scholes (@eq-black-scholes) is a mathematical model that seeks to explain the behavior of financial derivatives, most commonly options:

$$

\frac{\partial \mathrm C}{ \partial \mathrm t } + \frac{1}{2}\sigma^{2} \mathrm S^{2}

\frac{\partial^{2} \mathrm C}{\partial \mathrm S^2}

+ \mathrm r \mathrm S \frac{\partial \mathrm C}{\partial \mathrm S}\ =

\mathrm r \mathrm C

$$ {#eq-black-scholes}

```

I would like that, in the final HTML, only cross-referenced formulas are numbered (this is done with tags in html). No matter how I filter the labels, the final HTML always numbers all the labelled equations, not matter if they are cited or not. To lua filter the labels, I guess I need to know how the equations/labels are passed to pandoc.


r/quarto • • Aug 26 '24

AsciiDoc Inspired Extensions for Quarto

5 Upvotes

Two Quarto Extensions

Here are a couple of filters/extensions that were inspired by features from AsciiDoc

admonitions

admonitions adds AsciiDoc-style paragraph admonitions to Quarto.

simple_vars

simple_vars allows you to use the AsciiDoc approach to reference variables defined in a project level _variables.yml file.

Rather than using Quarto's var shortcode like {{< var variable-name >}} you can instead reference that variable in markup as {variable-name}.

The extension eliminates the need for all the extra braces, etc. Your markup is cleaner, but you still get the same output:

See the two linked repositories for examples and more details.


r/quarto • • Sep 06 '24

Any examples on how to have a photo gallery on a Quarto presentation?

4 Upvotes

Hi! I am an (rookie) enthusiast that loves to explore Quarto and R. I use Quarto presentations as my way to go to prepare my classes slides. Irt is mainy text slides but I would like to present some images and present the as a photo gallery would be awesome. Is there any good photo galleries that I should be aware of? Or I should quit that idea and present each image as an individual slide?


r/quarto • • Aug 12 '24

Help generating table properly in Quarto

4 Upvotes

Hi there,

I'm trying to get some tables to generate properly in Quarto. I am soliciting ideas for alternative methods of making these tables look as desired.

I would like this table to generate like this (input from visual editor):

It comes out like this when I render to PDF:

I'm having a hard time getting it to align e and o in in the Mid row correctly (i.e., e should be right aligned in its cell and o should be left aligned in its cell).

Thanks!


r/quarto • • Dec 20 '24

quarto vs marimo

13 Upvotes

I have the basic understanding of `quarto` (and using it on daily basis), and I'm trying to learn more about `marimo`, both being able to create interactive notebook and dashboard.

quarto seems to be more versatile in terms of the languages it can accommodate (r, python, julia, observablejs...) and the output formats it can generate.

marimo seems to be strong in its "reactive" way of handling notebook and generating web app that could be more performative than the traditional jupyter notebook.

I'd like hear your comments, based on your experiences, on the main pros & cons between them.

Thanks.


r/quarto • • Jun 18 '25

Quarto Book for splitting a large report — good idea?

2 Upvotes

I’m working on a large data analysis report in Quarto that I share with my supervisor. The document has become long and slow to render and open in a browser, so I’m considering splitting it up.

My current idea is to turn it into a Quarto Book, where each section of the report becomes its own .qmd file (e.g., import.qmd, qc.qmd, clustering.qmd, etc.), and render them all together into a single HTML file using self-contained: true.

I like that this should keep the output to just one file and should let me preview and edit chapters independently during development.

Has anyone else used this kind of setup? Does it scale well for long or complex analyses (with plots, tables, etc.)? Are there any caveats I should be aware of?

Would appreciate any thoughts or alternative suggestions!


r/quarto • • May 04 '25

[Quarto Book] How to use alternative chapter titles on sidebar?

4 Upvotes

I have a chapter with a long title. On the sidebar on the left, I want to replace it with a shorter title.

From this guide and this guide in the official docs, I tried to edit the _quarto.yml file like this:

book:
  sidebar:
    contents:
      - text: "Shorter Title for Chapter 1"
        href: chapter-1.qmd  

but it didn't work.

Any idea how to achieve this? Thanks.


r/quarto • • Mar 22 '26

Anounce alerts-normalize: a Lua filter to use GitHub alert syntax (> [!NOTE]) in Quarto

2 Upvotes

I built a small Lua filter that bridges GitHub alert syntax (> [!NOTE], > [!WARNING], etc.) to native Quarto callouts.

GitHub alert syntax doesn't seem to work in Quarto out of the box. The native solution uses a different syntax (::: {.callout-note}), which breaks portability with GitHub and other platforms.

The filter normalizes the syntax at the AST level before Quarto's callout processor runs (at: pre-ast stage), so you keep writing > [!NOTE] and Quarto renders native styled callout boxes automatically.

Features:

  • Auto-detects Quarto — no configuration needed

  • Custom alert types — any uppercase word, not just the five GitHub types

  • No silent failures — unrecognised markers pass through as plain blockquotes

Install:

quarto add plbarrio/alerts-normalize

Declare in _quarto.yml**:**

yaml

filters:
  - at: pre-ast
    path: plbarrio/alerts-normalize

https://github.com/plbarrio/alerts-normalize


r/quarto • • Apr 02 '26

Quarto 1.9 is now out

Thumbnail
quarto.org
26 Upvotes

Quarto 1.9 is now out! Lots of goodies in this release:

Publishing and cloud integration

- Direct publishing to Posit Connect Cloud with a free tier for unlimited static documents with the new quarto publish posit-connect-cloud command

Accessibility and standards

- Includes experimental PDF/A archival and PDF/UA accessibility compliance for LaTeX and Typst

- Alt text from fig-alt now passes through to PDFs for screen reader support

- Privacy-focused defaults include opt-in cookie consent.

Typst enhancements

- Book projects can now render to Typst with the bundled orange-book extension

- Article layouts support margin content and full-width figures, with custom font options (mathfont, codefont, linestretch) and color customization

- Theorem styling offers four appearances: simple, fancy, clouds, and rainbow.

Content and developer tools

- List Tables introduce a new bullet syntax for complex table content including code blocks and nested lists

- A new llms-txt format provides LLM-friendly output for AI-readable website content

- Synchronize brand assets with the quarto use brand command (GitHub, local, or zip sources)

- Engine extensions enable Julia and other execution engines as bundled extensions

- Plausible Analytics integration

Quality of life improvements

- Enhanced search includes persistent result highlighting

- The new syntax-highlighting option replaces the deprecated highlight-style

Learn more in the Quarto 1.9 blog post.


r/quarto • • Jun 19 '25

Not my course nor am I compensated

2 Upvotes

I registered for this course and am finding it very helpful. Figured I’d share with others who are looking to learn quarto. Please remove if not allowed.

I’ve been following Yan Holtz for years - this is his course.

https://www.productive-r-workflow.com

Thanks


r/quarto • • Oct 15 '25

Quarto-friendly ios apps?

3 Upvotes

I would like to work on my iPad sometimes, but the .qmd extension frustrates many iOS Markdown editors. Does anyone know of one that will allow opening and saving in .qmd? And that will support LaTeX math and HTML figure blocks?

thanks


r/quarto • • Jan 10 '24

how to create single-level hypothesis numbers

1 Upvotes

For academic research I needs an automated numbering of hypothesis. I adapted the theorem option. But it gives me two-level numbering. How can I change the options in such a way that I can get single-level numbering style. for the hypotheses? I use Quarto in RStudio. See the reproducible example below. Thanks.

---

title: "Title"

format:

pdf:

include-in-header:

text: |

\usepackage{newunicodechar}

\usepackage{setspace}

\usepackage{float}

\floatplacement{table}{H}

pdf-engine: xelatex

crossref:

thm-title: Hypothesis

thm-prefix: Hypothesis

thm-labels: alpha

title-delim: — # (default is ":")

block-headings: false

editor_options:

chunk_output_type: console

---

```{r setup, include=FALSE}

knitr::opts_chunk$set(warning = FALSE, message = FALSE)

```

# Introduction {#sec-introduction}

::: {#thm-cas}

hypothesis text

:::

referencing the u/thm-cas


r/quarto • • Jul 30 '24

Quarto docx export - extra square brackets

2 Upvotes

I'm trying to get a simple qmd file to export to docx. The qmd file is below. When I render the file, I get a docx file, but it has extra square brackets around section headings as shown in the attached screenshot. Any ideas on why these brackets are popping up and what can be done about this?

---
title: "Quarto Word Export Test"
format:
  docx:
    toc: true
    number-sections: true
    highlight-style: github
    number-depth: 3
---

# One

# Two

# Three

r/quarto • • Mar 12 '24

quarto publish to netlify w/o authentication

1 Upvotes

Hi,

so I have a website that I build with quarto and publish to netlify using quarto publish. This works fine.

However, everytime I re-render the website, I need to authenticate by opening my browser and accepting that quarto gets access.

THis is tedious in the long rung, especially since netlify requires you to re-login very often.

In my "_publish.yml" I have the standard setup from the docs, with -source: project' 'netlify -id -url' (I tried showing the content but reddits filter removes it, probably triggered by the 'id' field or something)

Is there a solution to this? It is possible to obtain an netlify authentication token, but in the docs, it seems like it only works if you setup your site with Github Actions or something. I don't need all that extra functionality, I just to be able to update my website quickly, using an authentication token, for example.

I gues using Github and Github Actions would solve it, since, per the documentation:

https://quarto.org/docs/publishing/netlify.html


r/quarto • • Aug 16 '24

Paths and location of .qmd

2 Upvotes

Hi,

I love Quarto but there's one thing I do not understand. Imagine I have a root folder that contains two folders, A and B. There are relevant files within folder A but I want my .qmd file in folder B.

How do I refer to those documents from the .qmd file? In RMarkdown I could select the root directory as the root for the path, but I do not know how to do this using Quarto. The solution I've found so far is locating the .qmd document in the root folder, but this is far from ideal.

Thank you in advance!


r/quarto • • Jan 14 '25

question about python version

1 Upvotes

Is there a simple way (e.g. modify the yaml file) to use python venv in the working folder instead of using the python from the path env variable?


r/quarto • • Feb 01 '24

Building a knowledge db with Quarto and Foam in VS Code

10 Upvotes

Hey guys, I love Quarto for literate programming and interactive things and ofc Single Source Publishing.

Coming from Obsidian I do miss connecting the documents and looking at a graph. Literate programming with executable code, single source publishing and linking and graph is totally possible with Org-roam, but I dislike that org is a file type that is rather niche. QMD ist more spread imho.

That's when qmd and Foam comes in. In theory Foam allows to use ANY file type as a note and indeed the workspace loads if you open a qmd file after you edited the settings towards it.

Unfortunately none of the links, no matter what syntax I use (Wiki or markdown) does work. What am I doing wrong? It doesn't even render.

EDIT: I made it work, tho it sometimes is wonky.

In the Foam settings, you have to add qmd as a note extension and only use markdown link syntax, not Wikilinks. In those you have to put in the file extension if it is not md and the relative path from the directory, so file B in File A

fil A

\- Project B folder

\\----- File B

has to have the link [Link Name] (Project B folder/File B.qmd). Since Quarto tends to escape all special characters including links, you need to write them in source code mode. In source code mode however, the links aren't clickable unless you are linking to a md File. When you switch to to Visual mode, it's perfectly usable again. The PDF however just visually puts the link. It's not actually usable.

I haven't tried executing code yet, but so far it's responding and even tags are recognized, both in yaml front matter and in free text form #tag.

Have fun. Mixing of file types does work btw.


r/quarto • • Jul 26 '24

Efficiency tips

3 Upvotes

I'm an academic scientist in biomedicine. I like the idea of writing articles/presentation with embedded code like Quarto allows. But in practice I find that I have difficulty predicting the output appearance, esp with revealjs output. So I'm wasting a lot of time repeatedly knitting the document to see if layout is appropriate.

  • does anybody have any recommendations to improve efficiency?

  • any revealjs templates for academic science presentations?