Partick Thistle have terminated the contract of Jordan McMillan following an internal investigation.
Lionel Messi will end his career at Barcelona, Chelsea manager Jose Mourinho believes.
The 24-year-old has scored in recent friendlies against East Fife and Manchester City and joins after a spell at Crystal Palace, although he did not appear for the Eagles.
Head coach Robbie Neilson told the club's official website: "I'm delighted to get Osman here. He's a tall, athletic player who will add strength to our forward line.
"He's a quality player and spent last season down in the English Premier League with Crystal Palace, so it's a bit of a coup to get him here.
"I've been impressed with him in training and with his appearances against East Fife and Manchester City. I'm very satisfied now with the attacking options that we have."
Sow, who is the club's eighth summer signing, said: "I'm happy to have signed for Hearts. It's a massive club which should be in the top flight.
"There's a good bunch of lads here and everybody is working hard. The staff have been brilliant so I'm happy.
"I'm happy to play my football here and I can't wait to do it as soon as possible."