The Nikkei stock index trimmed earlier gains to end almost flat Friday as profit-taking weighed after the index hit a five-month intraday high above the 10,000 threshold. The 225-issue Nikkei Stock Average rose 8.76 points from Thursday to 10,022.39. It briefly rose as high as 10,130.23 shortly after the opening, the highest intraday level since June 22. The broader Topix index of all First Section issues on the Tokyo Stock Exchange was up 0.71 point to 869.52.
The market initially got a lift from gains in high-tech, automakers, and bank shares as U.S. stocks jumped overnight, and the yen was soft against the dollar and the euro. But the upward momentum gradually lost steam as profit-taking emerged, brokers said. ‘‘It’s natural to see profit-taking after strong gains,’’ said Masumi Yamamoto, market analyst at Daiwa Securities Capital Markets Co.