A semiconductor device comprising a guard structure for guarding a high voltage region at a semiconductor surface from a low voltage region at the semiconductor surface; the guard structure comprising: a first layer of a first type of semiconductor in contact with a second layer of a second type of semiconductor; the second layer providing the semiconductor surface; a first trench and a second trench lying between the high and low voltage regions to isolate the high voltage region from the low voltage region; each of the first and second trenches extending from the semiconductor surface and entirely through the second layer to define there between a sub-region of the second layer between the high and low voltage regions that is isolated from the high and low voltage regions; and the semiconductor device comprising a circuit that connects between the high voltage region and the low voltage region; the circuit arranged to generate an intermediate voltage; the circuit comprising an output connected to the sub-region for applying the intermediate voltage to the sub-region; the intermediary voltage having a value between the voltages of the respective high and low voltage regions; characterised in that the guard structure includes a first set of lateral trenches that extend between the first and second trenches, across the sub-region, to divide the sub-region into sub-divisions, and wherein the circuit comprises a separate output connected to each sub-division to apply a different intermediate voltage to each sub-division. the guard structure comprising: a first layer of a first type of semiconductor in contact with a second layer of a second type of semiconductor; the second layer providing the semiconductor surface; a first trench and a second trench lying between the high and low voltage regions to isolate the high voltage region from the low voltage region; each of the first and second trenches extending from the semiconductor surface and entirely through the second layer to define there between a sub-region of the second layer between the high and low voltage regions that is isolated from the high and low voltage regions; and a first layer of a first type of semiconductor in contact with a second layer of a second type of semiconductor; the second layer providing the semiconductor surface; a first trench and a second trench lying between the high and low voltage regions to isolate the high voltage region from the low voltage region; each of the first and second trenches extending from the semiconductor surface and entirely through the second layer to define there between a sub-region of the second layer between the high and low voltage regions that is isolated from the high and low voltage regions; and the semiconductor device comprising a circuit that connects between the high voltage region and the low voltage region; the circuit arranged to generate an intermediate voltage; the circuit comprising an output connected to the sub-region for applying the intermediate voltage to the sub-region; the intermediary voltage having a value between the voltages of the respective high and low voltage regions; characterised in that the guard structure includes a first set of lateral trenches that extend between the first and second trenches, across the sub-region, to divide the sub-region into sub-divisions, and wherein the circuit comprises a separate output connected to each sub-division to apply a different intermediate voltage to each sub-division. <EOS>