* May core CPI up 0.8% yr/yr, matches forecast
* May core-core CPI up 0.5% vs +0.6% in April
* Inflation stays distant from BOJ's 2% target
TOKYO, June 21 (Reuters) - Japan's core consumer prices rose 0.8% in May from a year earlier, data showed on Friday, keeping the central bank under pressure to maintain or even expand its massive stimulus programme to achieve its elusive 2 percent inflation target.
The increase in the core consumer price index, which includes oil products but excludes volatile fresh food costs, matched a median market forecast and slowed from a 0.9% gain in April.
The data highlights the challenge the Bank of Japan faces in spurring inflation towards its 2 percent target, as trade frictions and slowing global growth cloud the outlook for the world's third-largest economy.
The so-called core-core CPI, which strips away the effects of volatile food and energy costs and is closely watched by the BOJ to gauge how much the economy's strength has translated into price gains, was up 0.5% in May from a year earlier.
The central bank has already conceded that it will take time to achieve its price target, stressing that it will ease policy further only if risks threaten to derail Japan's recovery.
The economy is holding up for now, expanding by an annualised 2.1% in the first quarter as the non-manufacturing sector maintains its pace on investment, tempering the gloom in the export sector, which more vulnerable to external headwinds.
But many analysts predict growth to slow in coming quarters as the U.S.-China tariff row hurts global trade. A scheduled sales tax hike in October may also curb consumption, they warn.
A downturn in consumer and business spending could cast doubt on the BOJ's argument that a sustained economic recovery will gradually prod firms to boost prices and wages, helping inflation accelerate. (Reporting by Leika Kihara; Editing by Sam Holmes)