Police and the air ambulance were called to the housing site in Whitstable yesterday but the 24-year-old was pronounced dead at the scene.
The young man from Canterbury in Kent is believed to have been working in a 6ft deep trench for sewer pipes when the sides collapsed.
Despite attempts to dig the man free, paramedics were unable to save him.
Health and Safety Executive inspectors are investigating and are being assisted by Kent Police who have arrested a man.
The housing site is located close to a primary school, which closed for the afternoon to prevent any distress for the children.
A spokesman for the Kent Air Ambulance said the man had suffered a cardiac arrest.