Safety and liability. Mains (230 V) wiring can be fatal. This page provides general information: it is not a set of installation instructions, and it does not replace an electrician, the product’s own instructions or the applicable standards. Leave the wiring to an electrician; if you do it yourself, you do so at your own risk. To the extent permitted by law, BudaiLux accepts no liability for damage arising from the use of the information on this page. More on liability
When you take down an old light, two, three, sometimes four wires hang out of the ceiling: brown, black, blue, green-and-yellow — and in an older home perhaps red or grey as well. The question is always the same: which one is live, which is neutral, and which is earth?
There is a standard for the colours, and it is worth knowing. But a colour only shows what the installer intended a core for, not what is actually on it. This article covers today’s colour code and older ones, the markings (L, N, PE, the earth symbol, the protection class on the light), and how to make sure, by testing, that there is no voltage.
Which colour is live?
Under the harmonised European colour code (HD 308 S2), live is brown, black or grey, neutral is blue and the protective earth is green-and-yellow. In a three-phase cable the order is brown, black, grey (L1, L2, L3). Older wiring may follow older national rules: in old Hungarian homes, for example, live is usually black and the protective earth may even be red. The colour is only a guide: which core is live has to be tested.
Safety note. The colour of a wire does not prove that there is no voltage on it. Before anyone touches a core, the circuit breaker has to be switched off and a two-pole voltage tester used to confirm that the circuit is dead — we describe this step by step below. If the test and the colours do not match, call an electrician. We recommend having any work on mains wiring done by a qualified electrician.
In Europe, the colours of the cores in cables and flexible cords are set by the harmonisation document HD 308 S2:2001, which each country adopts as a national standard. In Hungary it is MSZ HD 308 S2, in force since 1 May 2002. The basic principles and the letter codes for identifying conductors come from the standard EN IEC 60445.
The two most important rules are simple. Green-and-yellow is used only for the protective earth, and for nothing else. Blue is for the neutral. For line (live) conductors the standard recommends brown, black and grey, so in a single-phase lighting circuit the live may be brown or black.
| Colour | Letter | What is it? | Where will you see it? |
|---|---|---|---|
| brown | L or L1 | live (line conductor) | three-core flex for a light, single-phase circuits, phase 1 in three-phase |
| black | L or L2 | live | phase 2 in three-phase; in a single-phase circuit it may also be the live or the switched live |
| grey | L or L3 | live | phase 3 in three-phase |
| blue | N | neutral | every single-phase lighting circuit |
| green-and-yellow | PE | protective earth conductor (usually just called “earth”) | must be connected on a Class I light |

If it is a ceiling light or chandelier you want to connect, the steps and the switch types are shown with drawings in our article on wiring a ceiling light or chandelier. This article adds the basics: what the colours and the markings mean.
What is the letter for live, and what do L, N and PE mean?
The letter for live is L (from line, the line conductor). In a three-phase system the three phases are L1, L2 and L3. The neutral is marked N (neutral), the protective earth PE (protective earth). You will see the same letters on the light’s terminal block, on the terminals of switches and sensors, and on wiring diagrams.
- L — live. This is where the 230 V arrives. The switch breaks this conductor.
- N — neutral. The current returns along this. In normal operation it is close to earth potential, but in the event of a fault it can also carry a dangerous voltage.
- PE — protective earth. It carries no current in normal operation. Its job is to carry the current away from the light’s metal parts in the event of a fault, so that the protective device switches off.
- Switched live. The live that runs from the switch or sensor to the light. Manufacturers mark it in different ways (for example L’, an arrow or the number of the output); what it means is always given in the product’s instructions.
What is the earth symbol, and what does the protection class on a light mean?
The general earth symbol is a vertical line with three horizontal lines below it, getting shorter towards the bottom (IEC 60417-5017). On a light, however, you will usually see the protective earth symbol: the same sign inside a circle (IEC 60417-5019). It marks the terminal to which the green-and-yellow protective earth conductor must be connected.
Whether a light needs a protective earth at all depends on its protection class. The classes are defined in EN 61140, and the marking on lights is required by the safety standard for luminaires, EN IEC 60598-1. The symbol is on the rating plate or next to the connection terminal; what else has to appear on a light is covered in our article on CE marking.
| Class | Symbol on the light | What protects against electric shock? | Protective earth |
|---|---|---|---|
| Class I | protective earth symbol at the terminal (earth symbol in a circle) | basic insulation + metal parts connected to the protective earth | must be connected |
| Class II | double square | double or reinforced insulation | nowhere to connect it; insulate the end of the conductor |
| Class III | diamond with III inside | safety extra-low voltage (SELV), no more than 50 V AC | none; it may only run from the power supply intended for it |

A common situation: a green-and-yellow core comes out of the wall, but the light is Class II and has no protective earth terminal. In that case the protective earth does not need to be connected to the light, but do not cut it off: insulate its end, for example in a separate connector, so that it is there for a Class I light later.
What colours were wires in the past?
Older installations follow older national rules, which differed from country to country. Take Hungary as an example: its old installation standard, MSZ 1600-1:1977, was in force from 1 June 1978 until 1 February 2003. Under its point 7.52, for insulated wires live was black, neutral was light blue and the protective earth was green-and-yellow or red. Where the phases had to be told apart, their ends were marked with colour.
The most important lesson from this: in an old Hungarian home, a red core may well be the protective earth. Today red is not reserved for any of these roles, so without testing it means nothing. Cable standards changed too: the five-core cable in the 1998 Hungarian distribution-cable standard still had two black cores (green-and-yellow, black, blue, brown, black); three separate phase colours (brown, black, grey) became a uniform European rule only in 2001, with HD 308 S2.
| Role | Then, in Hungary: MSZ 1600-1 (1978–2003) | Today: HD 308 S2 (in Hungary since 2002) |
|---|---|---|
| live | black | brown, black or grey (L1, L2, L3) |
| neutral | light blue | blue |
| protective earth | green-and-yellow or red | green-and-yellow only |
| five-core cable | green-and-yellow, black, blue, brown, black (MSZ 146-6:1998) | green-and-yellow, blue, brown, black, grey |
Reality is even more mixed. An old home may combine decades of repairs, extensions and replacements, and sometimes several cores are the same colour. In wiring like this, the colour is at most a starting point.
Why test if the colours are clear?
Because the colour shows the installer’s intention, not the state of the wire. The core in the wall was not connected by the standard but by a person, and over the years several people may have worked on it. Four situations where the colour misleads:
- Wrong connection. If the switch mistakenly breaks the neutral instead of the live, the light stays live even when it is switched off: the live is still there in the lamp holder.
- Replaced or extended wire. During a repair, someone used whatever colour was to hand, not the standard one.
- Old wiring. The old colour code (in Hungary: black live, red earth) and today’s may be mixed in the same home.
- Several circuits in one box. A junction box may also contain a wire fed from another circuit breaker, which stays live after you have switched yours off.
Switching off at the light switch does not make anything dead either: the switch breaks only one core, and the live may still be present in the box. Only what has been switched off at the circuit breaker and then checked by testing can be treated as dead.
How do you check that there is no voltage?
With a two-pole voltage tester, in four steps. This is the instrument with two probes joined by a cable; its requirements are set out in the standard EN 61243-3. A tester like this shows the voltage between two points, and does not depend on how you are standing on the floor.

- Switch off the circuit breaker and put a note on it so that nobody switches it back on. If you are not sure which one it is, switch off the main switch.
- Try the tester on a socket you know is working. If it shows nothing there, the instrument is faulty.
- Test between every pair of cores where the work will be done: live–neutral, live–earth, neutral–earth, and if there are more cores, between every pair, regardless of colour. None of them may show any voltage.
- Try the tester again on the same socket. Only then can you be sure that it did not fail during the test.
Manufacturers explicitly require the last step. The instructions for one two-pole tester state that the correct operation of the device must be checked before and after every use, for example on a known voltage source.
Safety note. If you measure voltage between any pair of cores after switching off, or the result does not fit the colours, stop: this usually means a wiring fault or another circuit, and it is a job for an electrician. Do not work with wet hands, in a damp place, or on a ladder while holding on with one hand. An RCD (residual current device) reduces the risk of electric shock, but it is no substitute for making the circuit dead.
Why is a voltage-tester screwdriver not enough?
Because a voltage-tester (single-pole) screwdriver cannot reliably show that there is no voltage. Its neon lamp draws its current through you: if you are wearing insulating shoes or standing on an insulating floor, it does not light up even on a live wire. According to Electrosuisse, the Swiss electrotechnical association, a voltage-tester screwdriver is not permitted for establishing that a circuit is dead.
Electrosuisse lists four shortcomings: a failure of the neon lamp often goes unnoticed, its glow is often barely visible, it indicates lower but still dangerous voltages unreliably, and for a user standing on an insulated surface it does not light up even at a dangerous voltage. A tester screwdriver is only for a functional check, for example to see whether a switched socket has power.
The same applies to the single-pole “phase test” function of two-pole instruments: according to the manufacturer’s instructions, it must not be used to check for the absence of voltage either. Nor does Electrosuisse count non-contact voltage detectors or multimeters among the devices suitable for verifying that a circuit is dead.
When should you call an electrician?
If the colours and the test results do not add up, the job is no longer changing a light but finding a fault. In these cases, do not experiment:
- you still measure voltage between any of the cores after switching off;
- the switch visibly breaks the blue core, or the live is not where the colours say it should be;
- you want to connect a Class I metal light, but there is no protective earth in the box;
- there are several cores of the same colour, or red cores, and you cannot identify them with certainty;
- the insulation is burnt or crumbling, or the wiring is aluminium;
- you have no two-pole voltage tester, or you are not confident using one.
The same goes for outdoor lights with sensors: when wiring a motion sensor or a dusk-to-dawn sensor, a typical mistake is swapping the input and the output, which you will not notice without testing.
Frequently asked questions
Is brown or black the live?
Either can be live. The current standard recommends brown, black and grey for line conductors; in a three-core flex for a light the live is brown, and in a three-phase cable brown is L1 and black L2. In a lighting circuit, a black core may also be the switched live coming from the switch. Use a two-pole tester to find out which one is live.
Can a blue wire be live?
Not if the rules are followed: blue is for the neutral. But with a wiring fault, or in old, repaired wiring, a blue core may carry the live, and in the event of a fault the neutral can also carry a dangerous voltage. So treat the blue core as live too until it has been tested.
What are the colours of the three phases?
Under HD 308 S2, brown, black and grey, in that order, usually matched to L1, L2 and L3. The full colour sequence of a five-core cable is green-and-yellow (PE), blue (N), brown, black, grey. The older Hungarian cable standard (MSZ 146-6:1998) still had a second black core in place of the grey one.
What does the earth symbol in a circle on a light mean?
It marks the protective earth terminal (IEC 60417-5019): this is where the green-and-yellow protective earth conductor goes. A light with a terminal like this is Class I, and must not be used without the protective earth connected.
There is a red wire in an old installation. What could it be?
Anything. In Hungary, for example, red could be the colour of the protective earth under the old MSZ 1600-1, but in repairs it may also have ended up as a live, and old national codes elsewhere differed again. Today red is not reserved for any of these roles, so only testing will show what is on it — if you are unsure, call an electrician.
Sources
- Hungarian Standards Institution (MSZT), records of the national adoptions of the European standards (in Hungarian): MSZ HD 308 S2:2002 (identification of cable cores), MSZ EN IEC 60445:2022 (identification of conductors), MSZ EN 61140:2016 (protection against electric shock), MSZ EN 61243-3:2015 (two-pole voltage detectors)
- Hungarian Standards Institution: MSZ 1600-1:1977 (safety code for installations up to 1000 V, in force 1978–2003; in Hungarian); the colour rules of its point 7.52 are quoted by Villanyszerelők Lapja: Protective conductors and cable colours (issue 2007/4, in Hungarian)
- Hungarian Standards Institution: MSZ EN IEC 60598-1:2025 (luminaires, general requirements and markings; in Hungarian)
- Electrosuisse: Sicherheitsrisiko Phasenprüfer (in German, PDF) — why a voltage-tester screwdriver is not suitable for establishing that a circuit is dead
- Wiha: instructions for the 45216 two-pole voltage and continuity tester (multilingual, PDF) — an instrument to IEC 61243-3:2014, checked before and after use



