Portfolio Analysis10 min read

How to Calculate Portfolio Profit and Loss for PSX Stocks

PSX PORTFOLIOS Team

Why Accurate P&L Calculation Is Critical for PSX Investors

Profit and Loss (P&L) calculation is the foundation of investment performance measurement. Without accurate P&L data, you can't know which stocks are working, which strategies are profitable, or whether you should hold, buy more, or sell.

PSX P&L calculation is more complex than it appears — you need to account for broker commissions, CDC charges, weighted average cost across multiple buys, and the difference between realized and unrealized gains.

The Core P&L Formula for PSX Stocks

For any PSX stock holding, the fundamental P&L calculation is:

  • Total Investment = (Buy Price × Quantity) + Broker Commission + CDC Charges
  • Average Cost Per Share = Total Investment ÷ Total Quantity
  • Current Value = Current PSX Price × Quantity Held
  • Unrealized P&L = Current Value − Total Investment
  • P&L % = (Unrealized P&L ÷ Total Investment) × 100

The key insight: your break-even price is not your buy price — it's your average cost per share including all fees. This is the price the stock must reach before you're in profit.

Weighted Average Cost: The Right Way to Handle Multiple Buys

Most PSX investors buy the same stock multiple times at different prices. The correct way to calculate your cost basis is weighted average cost (also called average cost basis).

Example: You buy OGDC in three tranches:

  • Trade 1: 500 shares at PKR 150 = PKR 75,000
  • Trade 2: 300 shares at PKR 140 = PKR 42,000
  • Trade 3: 200 shares at PKR 160 = PKR 32,000

Total Investment: PKR 149,000 (plus commissions)

Total Shares: 1,000

Weighted Average Cost: PKR 149 per share (before commission)

If OGDC is currently trading at PKR 155, your P&L per share is PKR 6 (PKR 155 − PKR 149), and your total unrealized gain is PKR 6,000 on 1,000 shares.

PSX PORTFOLIOS automatically calculates weighted average cost every time you add a new BUY trade for an existing holding.

Realized vs. Unrealized P&L

Unrealized P&L (also called "paper profit" or "paper loss") is the gain or loss on shares you still hold. It changes every time the stock price moves. It's not real money until you sell.

Realized P&L is the actual profit or loss you locked in when you sold shares. It's calculated as:

  • Realized P&L = Sale Proceeds − (Average Cost × Quantity Sold) − Sell Commission

Example: You sell 500 of your 1,000 OGDC shares at PKR 160. Sale proceeds = PKR 80,000. Average cost per share = PKR 149. Cost of shares sold = PKR 74,500. Brokerage on sale (0.25%) = PKR 200. Realized P&L = PKR 80,000 − PKR 74,500 − PKR 200 = PKR 5,300.

Portfolio-Level P&L: The Full Picture

At the portfolio level, your total P&L is the sum of unrealized P&L across all open positions plus all realized P&L from closed positions. Key portfolio metrics include:

  • Total Investment: Sum of all capital deployed across all holdings (cost basis).
  • Current Market Value: Sum of current value of all holdings at live PSX prices.
  • Total Unrealized P&L: Current Market Value − Total Investment.
  • Portfolio Return %: Total Unrealized P&L ÷ Total Investment × 100.

Capital Gains Tax (CGT) on PSX Stocks

In Pakistan, Capital Gains Tax applies to profits from selling PSX shares:

  • Shares held for less than 1 year: CGT rate depends on your tax bracket (currently 12.5% for filers, higher for non-filers).
  • Shares held for more than 1 year: Currently exempt from CGT for individual investors in many cases.
  • Losses from one stock can offset gains from another in the same tax year.

PSX PORTFOLIOS tracks your realized P&L with trade dates, making it straightforward to identify which gains are short-term vs. long-term. Always consult a tax professional for your specific CGT obligations.

Common P&L Calculation Mistakes PSX Investors Make

  • Ignoring commissions: Not adding broker fees to cost basis overstates your real gains.
  • Using purchase price instead of average cost: If you bought at multiple prices, the last purchase price isn't your break-even.
  • Mixing realized and unrealized: Counting paper profits as actual money leads to overconfidence.
  • Not tracking partial sells: When you sell part of a holding, your remaining holding's average cost stays the same — don't reset it.
  • Using manual spreadsheets with stale prices: PSX prices move daily; a spreadsheet with yesterday's prices shows yesterday's P&L.

How PSX PORTFOLIOS Automates P&L Calculation

PSX PORTFOLIOS handles all of the above automatically. When you record each trade, the system:

  1. Applies your commission slab to calculate the exact fee for that trade.
  2. Updates the weighted average cost for the holding.
  3. Fetches the current PSX price to calculate live unrealized P&L.
  4. Tracks realized P&L separately when you record SELL trades.
  5. Aggregates everything at the portfolio level on your dashboard.

The result is an always-accurate, real-time view of your entire PSX portfolio — no spreadsheets, no manual calculations, no guessing.

P&L CalculationPSX Profit LossPortfolio AnalysisWeighted Average CostCGT PakistanPSX Stocks

Share this article

Share:

Stay Updated with PSX Market Insights

Get weekly updates on PSX market trends, portfolio management tips, and new features.

We respect your privacy. Unsubscribe at any time.