Fortunately, we do actually have a pretty good idea of how lightsabers are supposed to work thanks to the extensive technical manuals written by the Lucas team. But in addition to asking what a lightsaber is, and how it works, there's also another, perhaps more interesting question: what's the closest thing we could possibly make to that?
The first thing you need to know is the beam is not actually made out of light. The name is a misnomer like how "tin foil" is made of aluminium, not tin, and shooting stars, which are not actually stars. The most common and consistent description is that the lightsaber creates a powerful arc of plasma and then, via magnetic fields and the focusing crystal, that arc is pushed out into a long thin line. The beam is pushed out from the centre and then corralled into a straight edge with some kind of magnetic field confinement. We need to remember this bending is done with something very similar to the same force that allows Jedi and Sith to throw each other around.
It starts with something like this at its very core. A simple electrical arc as seen in this plasma arc speaker. In this case the arc is being modulated so the variations in the arc create recognisable sound and music.
Or this arc between two nails:
It is not too hard to imagine how, if that tiny ribbon were grabbed in the middle and somehow stretched out about a metre, it could become a lightsaber as they describe. The reality of the matter is far more complicated, but back to that in a moment.
Given the explanations above we can see that we actually already have something very similar as far as the essential technology and function of a lightsaber. Every day, we use "beams" of superheated plasma (some in in excess of 40,000 degrees) to easily slice through several inches of metal in factories all over the world.
The device is a plasma arc cutter/torch/welder/sprayer. In this simple diagram it even looks like a little like a lightsaber. Unfortunately this is where the similarities end. First, the actual arc is very small as shown by that tiny blue jagged line above. This tiny yet very hot arc ignites a gas that is continually pumped through the nozzle and the gas carries away the heat produced in a "beam" that acts as the working medium of this tool.
It still almost looks like a very tiny lightsaber. Jedi Master Mace Windu would probably love this arc welder. (Bonus points if you can guess why.)
The problem with plasma cutters is that the arc is not long enough to form a blade, and even with a continuous supply of gas, the arc is at most around 20cm long. Also, the devices require a huge amount of electricity to run and they produce a massive amount of waste heat in all directions. The tip of these devices has to have a continuous flow of water passing through to cool it down; otherwise, the arc would literally melt the entire tip of the cutter.
Some arc cutters use the gas itself as a cathode and the cutting surface as the anode, so the arc runs much longer and the heat is projected outwards away from the tips. This wouldn't work for a sword, as it is still very short and would require you first attach a high-energy cable to your opponent.
We simply do not have any effective way to bend the arc of energy far enough outward and then confine it in a magnetic field to keep it straight and narrow. Even if we could bend the arc outwards it would waver in random directions and eventually try to ground out on anything it touches. Additionally, as the sides of this arc got closer together it would just collapse into a shorter arc. Even if we could solve the first two problems we have excessive waste heat and a "blade" that is not rigid and cannot be used to block or parry.
We may have to go in a completely different direction if we want something even remotely like this as a weapon.
So we want a handheld weapon that can cut through various materials, has an extendable blade, and glows. The closest thing to that we might find, as Kevin Coe points out, would be with a few strands of carbon nanotube wire. These are then pulsed with electromagnetic field vibrations and/or plasma to give them some extra cutting power. This would effectively create a type of "energy vibro-sword", but without a solid backing behind the length of it, you would get a whip and not a blade.
Perhaps some kind of telescoping portion behind the cutting edge could contain a bundle of carbon-nano tube threads that are held in place and energised with plasma, creating a burning edge. The telescoping portion would also be made of advanced materials for strength such as carbon nanotubes and graphene. The rigid edge would be thin enough on one edge to follow through the hot cutting edge and thick enough at the other side to make a rigid parrying weapon.
To preserve the threads as long as possible and reduce energy and waste heat, the threads would not be energised until just before they hit. As the sword nears a target, a pulse of energy is sent through the threads at the leading edge of the blade. Little by little, some of the threads would be sacrificed as the charge moves from the outside edge to the inside wires, and eventually, the leading edge melts or burns away. In this way, the sword would continually ablate part of its material adding to the heat and cutting power but would necessitate continual feeding with more thread; the thread we are using is fortunately very thin. The thinness of this thread would also make it very good for cutting as we get a razor-thin edge.
You would still need a very large power pack (maybe backpack) possibly with some exotic energy storage medium and you would need heat protection for your hands and arms as well as special flare compensating glasses for your eyes.
A 3D rendering to give an idea of what this might look like:
Original artwork © by Ariel Williams, all rights reserved.
I designed and rendered this image and 3D model specifically for this post. The name, well that just came naturally after looking at it. Not to mention it just sounds plain awesome.