# Merge PDF Files in C#

> Merge PDF files in C#. Use the .NET library API to combine PDF documents into a single PDF file.

Source: https://products.aspose.com/slides/net/merger/pdf-to-pdf/
Updated: 2026-07-09



## Merge PDF to PDF using Aspose.Slides

[**Aspose.Slides for .NET**](/slides/net/) lets you create, convert, merge, and manipulate presentations, PDFs, and other documents. You can import pages from several PDF files into one presentation and save the result as a single PDF file.

## Merge PDF to PDF in C#

Using [**Aspose.Slides for .NET**](/slides/net/), you can load PDF files with `Slides.AddFromPdf` and save the result with `SaveFormat.Pdf`.

### C# code for merging PDF to PDF

```cs
using var presentation = new Presentation();
presentation.Slides.RemoveAt(0);

presentation.Slides.AddFromPdf("first.pdf");
presentation.Slides.AddFromPdf("second.pdf");

presentation.Save("merged.pdf", SaveFormat.Pdf);
```

## How to merge PDF in C#

Install **Aspose.Slides for .NET**. See [**Installation**](https://docs.aspose.com/slides/net/installation/).

Add the library as a reference in your project.

Create a `Presentation` object.

Load the PDF files with `Slides.AddFromPdf`.

Save the merged file with `SaveFormat.Pdf`.

## Merge other files
