A partnership between Greggs and Just Eat has surged to a £40m business in just 18 months, as the bakery chain increases its home delivery offering.

Greggs, known for its sausage rolls, steak bakes and vegan snacks, said that home delivery made up 8.5% of sales from company-managed shops in the first six months of the year.

The Newcastle-based business, which operates more than 2,100 stores nationwide, has introduced the Just Eat home delivery service to 837 stores since striking the deal last January. Revenues from company-run stores hit £488.3m in the first half, meaning that home delivery accounted for £41.5m.

Greggs hopes the burgeoning delivery business will help it build sales in the evening, where it currently lags in popularity compared with rival chains.

The company, which plans to hire 500 new staff as the business bounces back from the pandemic, said customers were becoming more used to pre-ordering food, either for delivery or to guarantee availability when they collected from a shop.

“Pre-ordering is a market trend that we believe will support, in particular, our ambition to grow sales in the evening, a segment of the market where we are currently underrepresented,” the company said. “Delivery will also have a role to play here, giving customers convenient access to Greggs’ products wherever they are throughout the day.”

The chain reported a £55.5m pretax profit in the 26 weeks to 3 July, compared with a £65.2m loss in the same period last year. It raised its profit guidance for the year and reinstated its dividend on the back of the strong performance.

Sales in the second quarter of the year were 2.8% higher than in the same period in 2019, after the reopening of non-essential retail outlets that led to more shoppers returning to high streets.

In the four weeks to 31 July, like-for-like sales were 0.4% higher than in July 2019, it added. Like-for-like sales in the first half of the year were down 9.2% on the same period in 2019, with the lockdown earlier this year hitting takings.

“Greggs once again showed its resilience in a challenging first half, emerging from the lockdown months in a strong position and rebuilding sales as social restrictions were progressively relaxed,” its chief executive, Roger Whiteside, said. “While there continue to be general uncertainties in the market, given our recent performance we now expect full-year profit to be slightly ahead of our previous expectation.”

Greggs said it opened 48 new stores in the first half, while closing 11, and is on track to add 100 outlets overall this year, with 70% of its recent openings in “car-accessed locations” such as roadsides, petrol stations, retail parks and supermarkets. The company plans to expand its overall estate from about 2,100 outlets to 3,000.

Outlets in public transport hubs and large city centres continue to lag behind those in high streets and suburbs as customers remain closer to home.

Greggs, which cut about 800 jobs last year, said it planned to hire 500 staff in the second half of this year.

It said it had repaid all money taken from the coronavirus job retention scheme in the first half of the year and was reviewing whether to repay the total of £90m it had received from the government during the pandemic.

Sign up to the daily Business Today email or follow Guardian Business on Twitter at @BusinessDesk

In May, Greggs, which last year reported its first loss since 1984, said its annual profit could reach 2019’s record level of £108m.

John Moore, a senior investment manager at Brewin Dolphin, said Greggs’ results showed its underlying strength as a business. “The company is feeling the full effect of a ‘return to normal’ along with the benefits of its investment in digital and the adaptations made to its estate to accommodate new customer habits during lockdown,” he said.