"With your computer on and Windows XP running, insert the disc into your computer. Setup should start automatically. If it doesn't, click Start, click My Computer, open the Windows 7 installation disc on your DVD drive, and then double-click setup.exe.
If you've downloaded Windows 7 rather than buying a DVD, browse to the installation file you downloaded, and then double-click it (often identified as an Application file under the Type column).
If you've created a bootable Windows 7 installation USB thumb drive, insert the drive into your computer. Setup should start automatically. If it doesn't, click the Start button, click Computer, double-click the drive, and then double-click setup.exe.
On the Install Windows page, click Install now. On the Get important updates for installation page, get the latest updates to help ensure a successful installation, and to help protect your computer against security threats. Now click I accept the licence terms, and then click Next.
Now on the Which type of installation do you want? page, click Custom. Choose the partition containing Windows XP (this is often the computer's C: drive), and then click Next.
In the Windows.old dialog box, click ok. Follow the instructions to finish installing Windows 7, which include naming your computer and setting up an initial user account. You can use the same names that you used in Windows XP, or choose new ones.
You will now need to copy back over all the files you backed up, and reinstall all your XP software packages. For more, visit our Windows XP migration hub."
Follow these procedure for installation of Windows 7 on an XP machine.