# Render a Visualforce Page as a PDF File

You can generate a downloadable, printable PDF file of a Visualforce page using the PDF rendering service.

Convert a page to PDF by changing the `<apex:page>` tag.

```visualforce
<apex:page renderAs="pdf">

```

A Visualforce page rendered as a PDF file displays either in the browser or is downloaded, depending on the browser’s settings. Specific behavior depends on the browser, version, and user settings, and is outside the control of Visualforce.

The following page includes some account details and renders as a PDF file.

```markup
<apex:page standardController="Account" renderAs="pdf">

<-- Placeholder CSS file, supply your own, with your branding, etc. -->
<apex:stylesheet value="{!URLFOR($Resource.Styles,'pdf.css')}"/>

<h1>Welcome to Universal Samples!</h1>

<p>Thank you, <b><apex:outputText value=" {!Account.Name}"/></b>, for 
   becoming a new account with Universal Samples.</p>

<p>Your account details are:</p>

<table>
<tr><th>Account Name</th>
    <td><apex:outputText value="{!Account.Name}"/></td>
    </tr>
<tr><th>Account Rep</th>
    <td><apex:outputText value="{!Account.Owner.Name}"/></td>
    </tr>
<tr><th>Customer Since</th>
    <td><apex:outputText value="{0,date,long}">
        <apex:param value="{!Account.CreatedDate}"/>
        </apex:outputText></td>
    </tr>
</table>
    
</apex:page>
```

![A Visualforce page rendered as a PDF](https://a.sfdcstatic.com/developer-website/sfdocs/platform/media/salesforce-pages-developers-guide/pages_output_pdf_renderas_simple.png "A Visualforce Page
Rendered as a PDF File")

- **[Render a Visualforce Page as PDF from Apex](/docs/platform/salesforce-pages-developers-guide/guide/pages-output-pdf-render-in-apex.md)**

  You can use the `PageReference.getContentAsPDF()` method in Apex to render a Visualforce page as PDF data. Then use Apex code to convert that PDF data to an email attachment, a document, a Chatter post, and so on.

- **[Fonts Available When Using Visualforce PDF Rendering](/docs/platform/salesforce-pages-developers-guide/guide/pages-output-pdf-supported-fonts.md)**

  Visualforce PDF rendering supports a limited set of fonts. To ensure that PDF output renders as you expect, use the supported font names. The default font is `serif`.

- **[Visualforce PDF Rendering Considerations and Limitations](/docs/platform/salesforce-pages-developers-guide/guide/pages-output-pdf-considerations.md)**

  Review these considerations and limitations when designing Visualforce pages intended to be rendered to PDF. Always verify the formatting and appearance of the PDF version of your page before you put it into production.

- **[Component Behavior When Rendered as PDF](/docs/platform/salesforce-pages-developers-guide/guide/pages-output-pdf-component-behavior.md)**

  Understanding how Visualforce components behave when converted to PDF is essential to creating pages that render well.

**See Also**

- [Using Custom Styles](/docs/platform/salesforce-pages-developers-guide/guide/pages-styling-custom.md)
- [Extending Salesforce Styles with Stylesheets](/docs/platform/salesforce-pages-developers-guide/guide/pages-styling-adding-stylesheets.md)
