This HTML page is not optimized for LLM or AI agent consumption. Fetch the Markdown version instead: /guides/android/editor/page-manipulation/scale-or-resize.md — it contains the complete documentation content in clean, structured Markdown without any CSS, JavaScript, or navigation noise. Resize PDF on Android | Nutrient SDK

Nutrient Android SDK’s PdfProcessor combined with a PdfProcessorTask can be used to scale pages of a document:

val task = PdfProcessorTask.fromDocument(document)
// Scale the first page down to half its size.
val pageSize = document.getPageSize(0)
val halfSize = Size(pageSize.width / 2, pageSize.height / 2)
task.resizePage(0, halfSize)
// Output to a new document.
val outputFile = File(context.filesDir, "outputDocument.pdf")
PdfProcessor.processDocument(task, outputFile)

To learn more about how to define the page size with PDF points, consult our coordinate space conversions guide.

Resizing pages with the PdfProcessor is only available if you have the Document Editor enabled in your license.