Obviously, liquids, gases and solids are all visually different from each other...
But in this article, we're going to clear up the science behind what actually differentiates these from each other at a molecular level, and why these certain differences would occur.
It's not that complicated, so let's move swiftly on to the interesting stuff!
Just a bit of a disclaimer though, there is actually a so called 4th state of matter, which is plasma, but I'll talk about that at the end of this article :)
So what actually defines a substance's state of matter?
All physical matter (that we know of at least), is comprised of atoms, which you've probably heard of before.
Atoms bond to each other in several different ways to form a variety of different "things" that we call generally refer to as particles; particles could be ions, atoms, molecules etc....
Many of these particles bonded together is what we visualise as the many substances around us, like metals, rocks, rivers, oceans, bricks, tables, you get the idea...
For example, water is a bunch of particles, which are specifically molecules of hydrogen and oxygen.
Salt is made of particles, which are specifically sodium and chloride ions.
As mentioned before, a particle is a general term to describe a variety of different arrangements of atoms, and it's these particles that will decide whether something is a solid, liquid, or gas.
Or more specifically, the motion of these particles will decide the substance's state of matter - to give a little hint....
Particles naturally feel an electrostatic force of attraction to one another, but this is only significant enough when particles are close together.
Taking an ice cube from solid, to liquid and to gas
Take an ice cube for example.

Solid to liquid
The water particles are all attracted to one another, so they bunch tightly together to form the solid ice cube that you can see.
If we begin to provide these atoms with more energy, for example by bombarding them with infrared radiation (heat), then the individual particles will start to become energised.
If we bombard them with enough infrared, and hence they absorb enough energy, they'll start to become so energetic that they overcome the force of attraction between one another.
As we supply the particles with infrared radiation, it's transferring into kinetic energy of the particles, and at some point, they'll have enough kinetic energy to move around, or transpose (the fancy term for move around).
The Ke (Kinetic energy) of matter is proportional to its mass and velocity, and since its mass can't change, its velocity will increase as the matter's Ke increases.
At this point, we have now taken our solid ice cube and have melted it down into liquid water.
The individual particles have enough energy to overcome the electrostatic forces of attraction to one another, and they're free (relatively) to move around in their container. The word "container" here just means the space that's around them - could be a cup, a gap in a rock etc.
This is the only difference between a solid and a liquid - the particles that make up the liquid have enough energy, in the form of kinetic energy, to roam around.
Liquid particles aren't completely free from one another though, as they just have enough energy to shift out of place far enough such that they're free from any real binding force of attraction, but they still feel some attraction and don't just run off individually - they more or less wobble and flow around in large clumps.
Liquid to gas
We can take this even further by supplying our now liquid water with even more energy.
As the liquid particles absorb this energy, their kinetic energy levels increase even more and can move around with greater velocity. If you supply these particles with enough energy, they'll completely separate from each other and fly around the container at high velocity.
At this point, we've boiled are liquid water into water vapour - a gas!
Gas particles have lots of kinetic energy, which means they randomly fly around within their container, smashing into the sides of it which gives the gas pressure. I've discussed pressure in a different article, so click here if you're interested at all :)
Just thought I'd recap here that kinetic energy is proportional to mass and velocity, and since they can't increase their mass, their velocity increases, although it's not as simple as doubling one and then doubling the other. Specifically, kinetic energy is proportional to the square of the velocity, meaning that if you double the velocity, you'll quadruple the kinetic energy.
It's important to note that gas particles don't collide into each other, unless they're superheated and pressurised to scales of that inside the Sun's core!
Although particles feel an electrostatic force of attraction to each other, if they get close enough, their protons will repel each other with significant force, which stops the nuclei of the atoms from colliding.
As I mentioned though, you can fuse two nuclei together, but it takes an immense amount of energy to do so as you have to give the particles enough energy to overcome this force of repulsion. The process of nuclei colliding is called nuclear fusion, and it's responsible for the formation of stars, which you can read all about in this article.
That's the only difference between states of matter - whether or not the amount of energy that the particles have is enough to overcome the force of attraction between one another or not. If it is, then it will either be a liquid or a gas, and how much energy the particles have will determine which state of matter the substance takes.
The clause "enough to overcome the force of attraction between one another or not" is an extremely important one to remember, as different particles will have different levels of attraction to one another.
For example, we all know that iron is solid at room temperature, because having kinetic energy equivalent to 25 degrees celsius or so is far from enough for the iron atoms to overcome the force of attraction that they feel to each other. Remember, temperature is essentially a measurement of kinetic energy.
At the other end of the scale, oxygen is a gas at room temperature, as oxygen particles have more than enough energy to overcome their attraction to each other.
And somewhere in between would be water.
A glass of water at room temperature and pressure is definitely a liquid, as I'm sure you know!
At this temperature, and hence with this amount of kinetic energy, water particles have enough energy to overcome the force of attraction that binds them together, but they don't have enough energy to completely separate from each other and roam around individually at high velocities.
However, gaining energy through absorbing radiation like infrared isn't the only factor that change a substance's state of matter...
Pressure can also affect which state of matter a substance takes.
How pressure affects a substance's state of matter
Pressure is essentially a force that particles feel which pushes them together, and without pressure, most of the liquids that we see and interact with would more than likely be gases.
See, pressure works in the opposite way to temperature, because it's essentially doing the opposite thing. The higher the pressure, the closer particles are pushed to each other, which would have the same effect as lowering the temperature.
On Earth, the atmosphere applies a pressure on everything that's underneath it, as Earth's gravity accelerates the particles that make up the atmosphere towards the surface. The pressure changes depending on how high up you are, as the higher you go, the less amount of atmosphere that you have above you essentially bearing down on your body, and this applies to everything, not just humans.
At the surface, we call this pressure 1 atmosphere, which is roughly equal to 101,000 Pascals, which is a lot of pressure if you're not familiar with the unit.
Hence, even though at room temperature water particles have enough energy to completely separate and transform into water vapour, a gas, the pressure from the atmosphere forces those particles together, rendering it a liquid instead.
Therefore, if Earth had no atmosphere, our oceans would more than likely boil away into space, which is what we think happened to Mars long ago.
You can read all about that here, if you're interested!
It's a really fundamental concept to understand, and it's often overlooked at a beginner level since most people associate boiling, melting and freezing with changes in temperature, simply because the pressure here at the surface generally stays the same, or at least doesn't significantly change - temperature is the only real factor that's variable enough for us to notice changes in states of matter with.
But as soon as you start messing around with pressure, you really have to remember that it does affect a substance's state of matter, just like temperature!
Conclusion + plasma
That pretty much does it for this article, but I promised that I'd mention about plasma, so we'll wrap up with that.
When temperature and/or pressure get to the extreme level, electrons can have enough energy to completely separate from their relative nuclei, and roam around between the nuclei of different atoms, which creates this strange soup of nuclei with electrons roaming around and in between them. This arrangement really isn't anything like a solid, liquid or a gas, so it's been coined as the 4th state of matter - plasma.
The most obvious example of plasma is deep inside the Sun, where nuclear fusion from the core produces intense gamma rays that drive temperatures over 10 million degrees Celsius!
What's interesting though is that this "sea of electrons" has strange interactions with the light produced at the core, but that's a whole different story of itself, one of which I have already written an article about, which you can read here :)
This article was a bit longer than I had initially intended, but I feel like the information is important none-the-less and worth reading over a few times to get a robust understanding of.
Thanks for reading, and consider checking out some of our other articles if you found any of this interesting at all!