There's many ways of achieving this. You should pick depending on how important the proof is and your budget.
Background (History, Theory)
This is an excellent question - one that has been asked and answered, in various forms, since at least Galileo's time:
Early astronomers used anagrams [...] to lay
claim to new discoveries before their results were ready for
publication. Galileo used smaismrmilmepoetaleumibunenugttauiras for
Altissimum planetam tergeminum observavi ("I have observed the most
distant planet to have a triple form") for discovering the rings of
Saturn.
Nowadays, this process is usually called trusted timestamping, and usually works with a commitment scheme, very much like Galileo's anagram. On digital media (text, pictures, video), the commitment is usually the result of applying a hash function to the original.
While the process of deriving a commitment is very much a solved problem, it's only a part of the process. Often, the difficult part is knowing to whom do you want to prove the timestamp.
For example, let's say you want to prove to a person P that you've taken a picture at time T. If you know that ahead of time, it's trivial: just derive a commitment C at time T and send it to P directly.
However, if you only learn who the person is after you've taken the picture, this is much harder - because you need to know, ahead of time, who (or what) the person trusts without knowing who the person is.
If you have absolutely no idea who P is, a good compromise is to send your commitment to entities a lot of people trust
In practice
For content that is not extremely important (e.g: you're trying to prove ownership of a photo), there's several easy steps you can take, especially if you don't care about the confidentiality of the content:
- Send it over a email or chat service (one where you can't edit your messages after sending them). You can send it to yourself or someone who P trusts.
- Publish it on a blog, forum or social media service (that doesn't allow silent editing of content)
- Include a timestamped social media post of a famous person in the photo / screenshot (this part proves that you created it after that time)
For content that is important legally (e.g: you're trying to prove someone committed a crime), the safest way is always to ask a notary, lawyer or solicitor.
If for whatever reason you can't, you might want to consider to:
Achieving confidentiality without a notary
Before you even begin, it's important to make sure that P will be have the technical knowledge to read your proof, or willing to get someone they trust to verify it.
Step 1 - derive a commitment
1.1 - Choose a cryptographic hash function. SHA-512 is as popular and secure as it gets for 2016.
1.2 - Get software for your computer that enables you to calculate the hash. Quick Hash GUI is open source and works on Windows, Mac and Linux. If you're a command line user, you can just type sha512sum
.
1.3 - Calculate the file hash, and save both the hash and a copy of the file. Be aware that many tools for viewing pictures can corrupt the file, making the hash change. The same is true for (non-plain) text and, to a lesser degree, video.
1.4 - You'll need to keep the original copy until you make the proof. This is easier said than done - see this article
Step 2 - distributing the commitment
You can now publish your commitment.
If you want to be as safe as possible, use several of the approaches discussed earlier in this answer.