If you mean the Windows password, you can follow the steps below:
1. Download Windows Password Key in another accessible PC.
2. Run the downloaded file and install it.
3. Burn a reset CD/DVD/USB with Windows Password Key.
4. Reset your Windows password with the created disk above.
If you mean the bios password, please refer to the following steps:
Step 1: Open your computer case to examine the motherboard. Remove the CMOS battery. Gently pry the battery from its housing and reinsert the battery after 10 minutes. If this works and you don’t see the password prompt, then you have successfully reset the BIOS password. Otherwise, follow the steps below.
Step 2: Locate the jumpers near the edge of the board or near the CPU or the CMOS battery. Find “Clear CMOS” or “Clear Password”. Place the jumper over the pins and restart your computer. If this doesn't work, try step 3.
Step 3: Enter a password after receiving the password prompt. If you have an Award BIOS, try “AWARD PW”. If you have a Phoenix BIOS, try “CMOS”.