Aug 25 (Reuters) - Foreigners continued purchases in Japanese stocks for a third consecutive week in the week to Aug. 19 as upbeat domestic corporate earnings and a rally in Wall Street's major indexes boosted sentiment further.

Overseas investors bought Japanese stocks worth a net 403.89 billion yen ($2.96 billion) last week, marking their biggest weekly purchase since July 22, data from exchanges showed.

They secured derivatives worth a net 426.18 billion yen but exited a net 22.29 billion yen in cash equities.

Investors scooped up a fresh batch of domestic firms last week, lured by their strong quarterly results. Discount store operator Pan Pacific International Holdings surged 12.7% last week, while Sundrug added nearly 10%.

The Nikkei share average and the Topix index rose over 1% each last week, in their third weekly gain in a row. The Nikkei also hit an over seven-month high in that week.

However, both indexes are set for a weekly loss this week as investors are cautiously awaiting for clues on the size of U.S. interest rate hikes, from the U.S. Federal Reserve's annual Jackson Hole conference, due to start on Thursday.

Meanwhile, Japanese bonds obtained a net 2.36 billion yen in foreign inflows last week, after witnessing a weekly outflow in the week before.

On the other hand, Japanese investors withdrew a net 72.2 billion yen out of overseas bonds after two weeks of purchases, while also disposing of foreign equities, worth 506.3 billion yen. ($1 = 136.6800 yen)

(Reporting by Gaurav Dogra and Patturaja Murugaboopathy in Bengaluru; Editing by Krishna Chandra Eluri)