Is there a difference between these two words? What is it?
As I found they both mean: to prove, demonstrate. They are also reported as a synonym in Duden.
First, beweisen is the term used in mathematics if you prove something. Second, it is also used if you prove yourself. In both cases, you cannot go with nachweisen.
Now let's get to their overlapping meaning of proving something to be true by using facts, evidence.
I don't think there's really a difference in meaning; however, you cannot always interchange these words. Their uses differs slightly.
When you establish proof of something to somebody, you say jemandem etwas nachweisen.
Dem Angeklagten konnte die Tat nachgewiesen werden.
There was a claim that the defendant committed a crime and they were able to give proof. If you'd like to go with beweisen, you must change it a bit:
Die Tat konnte bewiesen werden.
So, beweisen is merely about "give proof of something", while nachweisen can additionally take a dative object to indicate who's guilty.
Though, you can also apply the dative object to beweisen. But it's different and is, for instance, commonly used in the sense of proving yourself.
Ich konnte ihm beweisen, dass ich doch dazu fähig bin.
That simply means, that you proved something to someone. They now believe you that you were right.
Some more examples:
You'd go with "jemandem den Alkoholkonsum nachweisen" (proving that they drank alcohol) rather than "den Alkoholkonsum beweisen" (yes, people drink alcohol... who cares?!).
It's more common to say "jemandes Unschuld beweisen" than "jemandes Unschuld nachweisen" (or even less likely "jemandem seine Unschuld nachweisen", but this is based on the fact that only few people pronounce themselves guilty if they're not). So, you simply prove somebody's innocence.
Basically, you can use "(jemandem) etwas nachweisen" when you make a statement and then, afterwards, you give some prove to 'show' you're right. Thus, nachweisen is typically used when you give proof by merely presenting a document that proves your statement. Beweisen would sound slightly odd in that context.
For the sake of completeness, I'd like to mention that there also the phrases einen Nachweis erbringen and einen Beweis erbringen, respectively.
Für die Tat konnte kein Nachweis erbracht werden.
Du solltest schon einen Beweis vorlegen, wenn du mit solchen Behauptungen daher kommst.
Well they mean almost the same but you will have to use them differently.
Nachweisen always comes with something, which you have proven or somebody who you have proven to have done something.
Der Wissenschaftler konnte die Existenz von Sauerstoff nachweisen.
Der Polizist weist dem Dieb eine Straftat nach.
Der Polizist beweist, dass der Dieb eine Straftat begangen hat.
As you can see there is a grammatical difference but no difference concerning the meaning of the words.
A good question, but difficult to answer. Duden has seen this problem by only saying beweisen and nachweisen are just variants. The normal word is beweisen.
Nachweisen is typical for certain sectors such as chemistry and law and authorities.
Authorities need a special Nachweis for the death of a person. It is a special document called "Sterbeurkunde". A physician has to write a "Totenschein" and deliver it to the special authority that in turn gives out a "Sterbeurkunde", which is sent to the son or daughter. This document is a Nachweis for the death for other institutions such as banks etc. And for this special Beweis authorities prefer the special term Nachweis.
There are a lot of Beweise that someone is dead, e.g. when one does not breath anymore or one's body is cold. But authorities need and produce a special Nachweis.