How to Test a Trading Strategy on PSX Data Without Risking Real Money
A strategy that sounds good is not the same as a strategy that works. Before you risk real rupees, test it. This guide shows a practical, free way to do that on the Pakistan Stock Exchange: look back at past prices, then forward-test with practice money, then judge the result honestly.
What you can and cannot test here
- You can test: strategies that hold for days, weeks or months, such as buy-and-hold, DividendMoney that a company pays to the people who own its shares. It comes from the profit of the company. It can be cash, or extra shares (called bonus shares).Full list of terms → stocks, SectorA group of companies that do similar work. Banks, cement companies and oil and gas companies are examples of sectors.Full list of terms → rotation, monthly rebalancing, or buying after a fall.
- You cannot test: intraday trading, stop-loss or Limit orderAn order to buy or sell at a price that you choose, or a better price. If the market does not reach your price, the order does not complete.Full list of terms →, and short selling. Orders on Pak Stock Exchange are filled at end-of-day Closing priceThe price of a share at the end of the trading day. On this site, your orders are filled at the closing price.Full list of terms →, with no borrowing.
- Costs are not modelled. Practice trades carry no BrokerA licensed company or person that buys and sells shares for you. You need a broker to trade real shares on the stock exchange. The broker charges a fee, called commission.Full list of terms →, exchange charges or tax. Real ones will lower your result.
Step 1: Write the rules down
If you cannot write the rules, you cannot test them. Put these in one place before you trade:
- The stocks: which companies or sectors you will choose from.
- Entry: exactly what makes you buy (for example, a price fall of a set size, a dividend announcement, a ratio below a number).
- Exit: what makes you sell, including when you admit you were wrong.
- Size: how much of your money goes into each position.
- Holding period: how long you plan to hold.
Step 2: Look back first, with free tools
A quick look at the past tells you whether an idea is worth a longer test. It does not prove anything, but it can rule ideas out.
What an amount in any PSX stock on a past date would be worth today. Price only, so dividends are not added. Stock Comparison
Two to four stocks side by side on return, volatility and drawdown. Stock Risk Statistics
Volatility, maximum drawdown and best and worst years for one stock. Portfolio Risk & Return
How a mix of stocks with your weights behaves, with a correlation matrix.
Pay most attention to the maximum drawdown: the biggest fall from a peak. Ask yourself whether you would really have held on through it.
Step 3: Forward-test with practice money
Looking back is easy, because you already know what happened. Forward testing is the honest test: you decide before the prices move.
- Start fresh. A competition gives everyone the same practice money and a clear start and end date, which keeps the test clean. See how the competitions work.
- Follow your rules exactly. If you change them halfway, you are testing a different strategy.
- Run it long enough. A few weeks at the least, ideally a few months, and enough trades to mean something.
- Log every trade: date, stock, the reason, the price, and what happened.
Step 4: Compare it with the market
A profit does not mean the strategy is good: in a rising market most things go up. Compare your result with:
- The KSE-100. Pak Stock Exchange gives a “Beat the KSE-100 indexThe main share index of the Pakistan Stock Exchange. It follows the prices of 100 large companies and shows if the market is going up or down overall.Full list of terms →” badge to players who are ahead of the IndexA number that follows the prices of a group of shares. It shows how that part of the market is moving. The KSE-100 is the best-known index in Pakistan.Full list of terms → after at least 30 days, as long as a meaningful part of their money is in stocks.
- Buy and hold. Would a simple buy-and-hold of the same stocks have done as well, with less effort?
- The rankings. See how your PortfolioEverything you own as an investor, taken together: your shares and your cash.Full list of terms → compares on the leaderboard.
Step 5: Judge the result honestly
- Sample size: five trades prove almost nothing. A good run can be luck.
- The path matters: how deep was the worst fall, and could you have lived with it?
- Costs: real brokerage and tax will reduce the result. Be conservative.
- Be ready to be wrong: a strategy that fails in practice has saved you real money.
Common mistakes when testing a strategy
- Fitting the rules to the past until they look perfect on old data, then finding they fail on new data.
- Looking ahead: using information you would not have had on the day.
- Ignoring stocks that were delisted or suspended, which makes old results look better than they were.
- Ignoring liquidity: a stock that rarely trades may not be easy to buy or sell in real life.
- Changing the rules after a loss, and counting only the trades you like.
A simple trade log
| Date | Stock | Buy or sell | Why (which rule) | Price | Result and what I learnt |
|---|---|---|---|---|---|
Questions about testing a strategy
Where can I test my trading strategy using Pakistani stock data?
Look back with the free tools on Pak Stock Exchange (If I Had Invested, Stock Comparison, Stock Risk Statistics, Portfolio Risk), then forward-test the strategy with Rs. 10 lakh in practice money at real PSX end-of-day prices. Competitions give a clean start and end date, and the rankings show how you did against others.
Can I backtest a strategy automatically on this site?
No. There is no automated backtester. The look-back tools show how a past investment or a mix of stocks would have performed, and the simulator lets you test a strategy going forward. Programmers can build their own backtest from public data, see the PSX data project ideas for CS students.
Can I test intraday or day-trading strategies?
No. Orders are filled at end-of-day closing prices, so strategies that depend on prices during the day, stop-losses, limit orders or short selling cannot be tested. Strategies that hold for days, weeks or months can.
What is the best way to test whether a strategy works before using real money?
Write the rules first, look back at past data, then forward-test for at least a few weeks or a full competition, keep a record of every trade, and compare the result with the KSE-100 and with simply buying and holding. A handful of trades proves very little.
If my strategy works in practice, will it work with real money?
It might not. Real trading adds brokerage and other costs, tax, price limits, thin trading in some stocks and emotions. Practice results are evidence, not a promise.
Test your idea with Rs. 10 lakh in practice money on real PSX prices. Free, no real money.
Start Virtual TradingLast checked October 2026. General education only, not investment advice. Past performance does not guarantee future results. See our disclaimer.
See it in practice
Join free and follow the market with practice money, using real PSX end-of-day prices.
Start free