What is FIFO method. FIFO is First In First Out. FIFO is the default method for cost basis calculation on almost all trading platforms.
Say, you buy a stock of XYZ for 100 dollars. If it goes up to 120 and you sell it, that’s a profit of 20 dollars. Now, if you had two shares, one you bought at 100 and the second one at 110, the average price is (100+110)/2 which is 105. If you sell those two shares at 120, the net profit is 15 per share.