The former technical manager of Herefordshire insulation maker whose product was used on Grenfell Tower has apologised for reacting to queries about fire safety by writing they "can go f*** themselves" and threatening legal action.

Philip Heath, who still works for Kingspan, also said sorry after forwarding a legitimate fire test inquiry from a customer and writing that he thought they were "getting me confused with someone who gives a dam" and "imagine a fire running up this tower!!!!!!!!!!".

In October 2008 emails, an employee of facade engineers Wintech made detailed inquiries of Kingspan, which makes insulation at a site near Leominster, seeking clarity on what basis its Kooltherm K15 insulation was suitable for buildings taller than 18 metres.

A Kingspan employee said it was "getting tricky what to write" without "putting ourselves in a legal situation".

Mr Heath wrote in an internal response: "Wintech can go f*** themselves, and if they are not careful we'll sue the a*** of them".

Inquiry lawyer Kate Grange QC asked: "Can you explain why you wrote that, given Wintech were giving entirely accurate advice to their customers?"

Mr Heath said: "It was totally unprofessional and on reflection I wouldn't have said that. I think it was frustration we were going around in circles with them."

He was asked if it reflected a "culture" within Kingspan "in terms of its response to these kinds of requests".

Mr Heath said: "I don't believe so. Like in any organisation, you have your good times and your difficult times.

"We were just going around in circles and a bit of frustration came out there on a Friday.

"I think we did take life safety seriously. We provided Wintech with the data we had for them to make the appropriate analysis."

Mr Heath, now divisional business development director at Kingspan, also apologised after reacting to a similar inquiry by writing that the firm making the request was "getting me confused with someone who gives a dam".

He added in the forwarded email: "I'm trying to think of a way out of this one, imagine a fire running up this tower !!!!!!!!!!!!!!!"

Mr Heath told the inquiry he had forwarded the email to a terminally ill friend, adding: "I can only apologise for the contents of this email at the time made in 2008.

"Keith was a dear friend of mine who was terminally ill at the time. I was just forwarding him an email to give a snapshot of some of the work I was working on.

"It had no reflection on how I felt, I was just trying to lighten his load and lighten my load."

The inquiry earlier heard Kingspan technical managers did not consider withdrawing K15 from the market even after a new version "burnt very ferociously" and failed a fire test in December 2007.

Mr Heath told proceedings that, "on reflection, yes" he ought to have considered withdrawing K15 for the over-18 metre market after analysis in April 2008 noted the newer product had a "quicker time to ignition and double the heat output".

Kingspan has acknowledged "process shortcomings during the period of 2005 to 2014 for which it sincerely apologises".

However, it said building regulations at the time permitted K15's use on tall buildings providing the overall cladding system was compliant.

The firm has said it did not provide any advice about the suitability of K15 for use on Grenfell Tower, and that the firm only learned a small amount of the insulation had been used on the building after the June 2017 fire, which killed 72 people.

The bulk of the insulation used on the tower was made by rival firm Celotex.

A letter from Kingspan to the inquiry last month said a test pass cited to approve K15 on high-rises since 2005 has been withdrawn.

The letter said: "It became apparent that the K15 manufactured in 2005 would not be representative of the product currently sold on the market from 2006 to today.

"While both products are still phenolic foam, Kingspan is now of the view that there are sufficient differences to consider withdrawing the test report."

The inquiry continues.