Stalin seems to have had a better reputation, or at least much better PR, during his lifetime. Especially during WWII, when the USSR joined the Allies, and the Communist Party USA was at its most popular.
This of course changed after his death, when Khrushchev took his place and denounced him in his 'secret speech'.
So what was the contemporary view of Stalin back then?
Your question is touching on the perception of Joseph Stalin both inside and outside the Soviet Union, understandably there's a big difference between those two.
With respect to Stalin's perception inside the Soviet Union, the man had one of the most deeply entrenched cults of personality that has ever been established. Even to this day, with his culpability in the purges, the plots, the cold-blooded murders of allies, the geopolitical maneuvering that directly resulted in the deaths of million of Russians, as well as myriad other similar atrocities all well known-- Stalin is still a contentious figure in Russia; you can find ardent supporters and detractors in almost any circle, educated or otherwise.
When discussing Stalin's perception abroad, however, I think it's important to look at three critical periods of time:
Stalin inside the Soviet Union
As I mentioned above, Stalin's cult of personality was absolute. There was no question to his authority and no challenge to his power. If you've read 1984 by George Orwell or are familiar with the character of Big Brother, you're beginning to understand how Stalin was portrayed, and even, how he portrayed himself.
From 1984, the main character Winston is having a conversation with his party interlocutor O'Brien while under arrest:
“Does Big Brother exist?"
"Of course he exists. The Party exists. Big Brother is the embodiment of the Party."
"Does he exist in the same way as I exist?"
"You do not exist.”
Compare this with an exchange Stalin had with his son Vasily Stalin (who took his father's revolutionary name instead of his actual family name Dzhugashvili) upon the former discovering the latter trying to use their shared surname in order to receive preferential treatment in his personal affairs:
Vasily: [In protest to Stalin rebuking him for trying to curry favor with his name] But I am a Stalin too!
Jospeh Stalin: No you're not. You're not Stalin and I'm not Stalin. [While pointing to a portrait of himself mounted on a wall nearby] That is Stalin. Stalin is Soviet power. Stalin is what he is in the newspapers and portraits, not you, no, not even me. ^([1])
Stalin was Soviet power. Soviet power was Stalin. Compare this with the Gospel of John 1:1 (KJV translation):
In the beginning was the Word, and the Word was with God, and the Word was God.
I hope I don't seem like I'm trying to swing for the fences too much here, but you can see in all of these excerpts the direct likening of the figure to the idea: Big Brother is the party, Stalin is Soviet power, God is the word. That is fundamentally important to Stalin's cult of personality-- and not accidental. Stalin was an avid reader and student of history, upon his death his personal library had more than 10,000 works in it.^([2]) He was also an avid student of Marxism-Leninism, often referring to Leninist writings long after Lenin himself had died. In this answer I touch on the identity crisis the Soviet Union went through as it transitioned from a "post-nation-state nation-state" to a more traditional nation-state. Traditional nation-states have a foundational story-- this is central to political science. Stalin understood this and made sure that the USSR was no exception.
Backing down from the broad strokes and big ideas of those conceptual paradigms, what did Stalin's cult of personality look like for the average Soviet citizen? You can imagine that, despite widespread Marxist-Leninist philosophical lessons throughout the nation, the typical Soviet citizen didn't have time for the navel-gazing pursuits of contemplating things like the foundational canons of the country in which they lived. These people had jobs, families, and no effective hand in the management of their own country. What they also had was consumption media.
Mikheil Gelovani was a Georgian actor who portrayed Jospeh Stalin several times. Examining how he was portrayed offers keen insight into the cult of personality as it was presented to the ordinary citizen. Consider Великое Зарево^([3]) (translated The Great Dawn): this 1938 film features two fundamental points that Stalin and his clique implanted into the public consciousness concerning Stalin's participation in the October Revolution:
Many similar such films were released during Gelovani's lifetime, with increasing amounts of exaggeration and out-and-out falsehoods, but The Great Dawn was the first of such films and therefore, the most important in the creation of Stalin's cult of personality.
When discussing Stalin's perception within the Soviet Union, of course, no conversation can be complete without an explicit mention of the travesties of the purges he unleashed upon the Soviet people between 1936 and 1938. The Henry M. Jackson School of International Studies at the University of Washington provides this brief summary on the effects of the purge far more concisely than I could:
More than a third of Communist Party members died during the purges. More than half of the Central Committee was killed. Eighty-one of 103 of the highest-ranking military leaders were executed. [...]
Ordinary citizens were affected as well. As the terror spread across society, people were coerced into denouncing their friends, coworkers, and even family members in an attempt to save themselves. Those arrested were often tortured and forced to sign documents confessing to extraordinary crimes and conspiracies. They were labeled enemies of the people and sentenced to death or hard labor.
Millions were sent to prison camps between 1936 and 1938. Many of the camps were located in the far reaches of Siberia or the Russian Far East, where conditions were extreme. Hundreds of thousands died while in Gulag prisons. ^([4])
The key thing to remember here is that because those sent to the camps were "convicted" under false pretenses of disloyalty, the fact of the matter is that Stalin wasn't purging traitors or even doubters-- he was purging loyalists. If anyone inside the Soviet Union had a negative opinion of Stalin, there was no way for them to communicate it. In fact, the famously unattributable but cliche refrain of this time among the Soviet populace with respect to the widespread mass arrests, torture, and terror was 'if only Stalin knew!'