Pip value: why the same pip is worth different amounts
Ask three traders what a pip is worth and you get "ten dollars", "a dollar" and "it depends". The third answer is the correct one. A pip is a unit of price movement, and turning it into money takes three inputs: the pip size, the position size and the currency the profit is expressed in.
Pip size
For most pairs the pip is the fourth decimal place, 0.0001. For pairs quoted against the Japanese yen it is the second decimal place, 0.01, because the yen has a much smaller unit value and prices look like 150.25 instead of 1.0825. Most brokers today also show a fifth decimal (or a third one for yen pairs), often called a pipette or fractional pip, which is a tenth of a pip. Charts and platforms that display "points" usually mean that smaller unit, so 10 points can be 1 pip. Check which one your platform uses before you compare numbers.
From price step to money
A standard lot is 100,000 units of the base currency. The profit from one pip is that position size multiplied by the pip size, and the result is expressed in the quote currency:

For EUR/USD the quote currency is the dollar, so one pip on one standard lot is 100,000 × 0.0001 = 10 USD. For USD/JPY the same calculation gives 100,000 × 0.01 = 1,000 yen per pip. If your account is in dollars, that is converted at the current USD/JPY rate: at 150.00 it is about 6.67 USD, and it changes as the rate moves.
Why this matters when you write software
If you build a journal, a risk calculator or a backtester, three mistakes come up again and again:
- Hard-coding 0.0001 as the pip size. Yen pairs and some exotic pairs, and several metals and index CFDs, do not follow it. Take the pip size from the instrument specification, not from a constant.
- Assuming a pip value in dollars. When neither currency of the pair is your account currency (say GBP/CHF in a USD account), the pip value needs a conversion rate from a third pair.
- Mixing pips and points. Keep one internal unit, usually the smallest price increment (tick size), and convert only for display.
Brokers publish contract specifications with the tick size, tick value and contract size per instrument, and the MetaTrader platforms expose them as symbol properties. Read them from there. Two brokers can quote the same pair with different digit counts, and code that reads the specification handles both without changes.
A quick sanity check
Because the numbers are easy to get wrong silently, keep a few known cases as unit tests: EUR/USD 1 lot = 10 USD per pip, USD/JPY 1 lot at 150.00 = 1,000 / 150 = 6.67 USD per pip, and one pip on a mini lot (10,000 units) is one tenth of a standard lot's value. If those pass, the plumbing is right and the remaining question is only which rate you used for the conversion.
When neither currency is your account currency
The trickiest case is a pair where neither side is the currency your account is held in, for example GBP/CHF held in a USD account. The pip value comes out in the quote currency first, Swiss francs here, exactly as usual: one standard lot of GBP/CHF has a pip worth 100,000 × 0.0001 = 10 CHF. To use it in a USD account, that figure still has to be converted, through USD/CHF this time, a currency pair that does not even appear in the position itself. At a USD/CHF rate of 0.8000 francs per dollar, 10 CHF is 10 / 0.8000 = 12.50 USD per pip. Get the conversion pair's quoting direction wrong, dividing when you should multiply, and every risk figure the tool reports is off by the square of the exchange rate rather than a simple rounding error, which is large enough that a small position can look far safer or far riskier than it is. This is the calculation an automated risk tool has to run silently, correctly, for every pair that does not happen to contain the account currency, and it is worth a dedicated unit test with a known third-currency pair rather than trusting that the general formula was implemented correctly by inspection.