EXCLUSIVE

Nipsey Hussle Life in Danger ... Days Before Murder

Someone was out to kill Nipsey Hussle just days before he was murdered ... and those working with him were warned as such, and took extreme measures to protect him.

Nipsey filmed a music video Thursday for an upcoming song he, DJ Khaled and John Legend collaborated on called "Higher." The track will appear on Khaled's upcoming album.

RIP Nipsey. I just spent Thursday with him filming a video for a beautiful new song we created with Khaled. We filmed in Inglewood, close to where he grew up. He was so gifted, so proud of his home, so invested in his community. Utterly stunned that he's gone so soon.

Sources on the Inglewood set tell TMZ ... there was great concern over Nipsey's safety during the shoot ... specifically over the parking structure the crew used to film. Our sources say the production team wanted the entire structure shut down so that only folks working the shoot would have access.

We're told production only booked the top two floors of the parking structure. People were able to park underneath the top floors.

More shocking ... our sources say the production hired 10 armed police officers because of concerns over Nipsey's safety. It's unclear why, but we're told they were scared someone would try sneaking on set and killing him.

Seems the protection worked ... our sources tell us things went off without a hitch.

Having strong enemies is a blessing.

Of course, just a few days later ... Nipsey was gunned down in front of his own storefront, no less. Just hours before the shooting, Nipsey cryptically tweeted about "enemies."

Police are still looking for the shooter, who's only been described as a black male in his 20s. Cops have said they suspect the killing might be gang-related.

Nipsey was only 33. RIP

Click here for info about our online advertising practices.