01. Make sure your Pages window visible.
In the document you wish to add page numbers to. Activate it by selecting Window > Pages.
02. Edit your master page.
Within the page palette double click on A-master (you can do this by clicking on the text or page icon). Now you are editing the master page.
03. Add a text element.
Select the text tool from your Tools menu (T), if the tool bar is not visible you can activate it by selecting Window > Tools. Create a text box which is wide enough to hold your required amount of numbers.
04. Turn the text element into an automatically generated page number.
Select Type > Insert Special Character > Markers > Current Page Number. Once you have completed this step a capital "A" will automatically appear. This “A” is the “A” master page. Here, you can select the text box to style it to be whatever you want your page numbers to look like.
05. Preview your page numbers.
Switch back and select your main pages to see that every page is numbered. These numbers are located in the master page and cannot be edited here. To edit the number go back into the master page and use the techniques outlined in steps 2-4.