Productivity and Utilities

Virtual Memory Address Translation Calculator

Enter the page size, the page table and the addresses to translate.

Your numbers

From 12 to 64.

One line per mapped page: page number, a colon and frame number. Decimal or 0x hexadecimal. Pages left out are not in memory.

One per line, decimal or 0x hexadecimal.

Result

First address

0x7345

0x12345 is page 0x12 with offset 0x345.

Offset bits
12
Page number bits
20
Pages in the address space
1048576
Page faults in the list
1
Pages mapped
3

Translations

Virtual (hex)Page (hex)Offset (hex)Frame (hex)Physical (hex)
x12345x12x345x7x7345
x13FFFx13xFFFx2x2FFF
x15000x15x0Page faultNone
How this was calculated
  1. With 4096 byte pages the offset is the low 12 bits and the page number is the rest.
  2. The page table maps the page number to a frame number. The physical address is the frame number followed by the same offset.
  3. A page that is not in the table causes a page fault, and the operating system must load it before the access can finish.
  • This models one level of translation. Real systems use several levels, a TLB and permission bits, which are not shown.

Calculated using SumPanda.com · https://sumpanda.com/virtual-memory-address-translation-calculator/

Results are estimates for general information. Verify important figures before relying on them.

Next step

How to use the virtual memory address translation calculator

  1. Choose the page size and enter the virtual address width in bits.
  2. Enter the page table, one mapped page per line: page number, a colon and frame number. Decimal numbers and 0x hexadecimal both work.
  3. Enter the virtual addresses to translate, one per line.
  4. Read, for each address, the page number, the offset, the frame and the physical address, or a page fault when the page is not in the table.

Formula

Offset bits = log2(page size). Page number = virtual address shifted right by the offset bits.

Offset = the low offset bits of the virtual address

Physical address = (frame number shifted left by the offset bits) combined with the offset

A page that is not in the page table causes a page fault

The page table maps whole pages, so the offset is copied unchanged from the virtual address to the physical address.

4 KiB pages and the address 0x12345

With 4 KiB pages the offset takes 12 bits and a 32-bit address has 20 bits of page number, so the address space has 1,048,576 pages. The address 0x12345 has page number 0x12 and offset 0x345. If page 0x12 is in frame 0x7, the physical address is 0x7345.

The address 0x13FFF is page 0x13 with offset 0xFFF, and in frame 0x2 it becomes 0x2FFF. The address 0x15000 is page 0x15, which is not in the table, so it causes a page fault. With 1 KiB pages and 16-bit addresses, the decimal address 1500 is page 1 with offset 476, and if page 1 is in frame 0 the physical address is 0x1DC.

What the numbers mean

Virtual memory gives each program its own address space, split into pages of equal size. The operating system keeps a page table that records which frame of real memory holds each page, and the hardware translates every address on the fly. A page that is not in memory causes a fault, and the system loads it from disk before the access can finish.

Caches work with addresses in a similar way. See the cache replacement policy simulator and the binary calculator for converting addresses between bases. For byte order in memory, use the byte order swap calculator.

What is simplified

Real systems use several levels of page tables, a translation buffer to speed up lookups, and permission bits for reading, writing and running code. The page models a single flat table to show the core idea. Check that the page numbers in your table fit in the address width, which the page does for you, since a page number needs address width minus offset bits.

To see how the processor is shared among programs, try the CPU scheduling simulator.

Assumptions and limits

  • One level of translation with a flat page table and a power of 2 page size.
  • Addresses are decimal or 0x hexadecimal, and fit in the address width you give.
  • A page missing from the table is a fault. Permissions and a translation buffer are not modeled.
  • The page allows up to 200 addresses at a time.

Formulas reviewed October 10, 2026. See the calculation methodology for how SumPanda rounds, tests and sources its formulas.

Frequently asked questions

How do I split a virtual address?

The low bits, as many as log2 of the page size, are the offset. The remaining high bits are the page number.

How do I find the physical address?

Look up the page number in the page table to get a frame number, then put the offset after the frame number.

What is a page fault?

It happens when the page is not in physical memory. The system must bring it in before the program can continue.

Why do page sizes have to be a power of 2?

So the offset is a whole number of bits and the translation is just bit shifting and masking.