A homeless man offered libations and a toast on Tuesday to the four vagrants who were killed while sleeping in Chinatown – using booze he bought with money left at a makeshift memorial to the victims.

The poignant scene, witnessed exclusively by The Post, unfolded in Kimlau Square, where mourners arranged candles, flowers, fruit and other items in the corner of a large planter near the scene of Saturday’s fatal bludgeonings.

The man was visibly upset as he and a pal approached and stared at the memorial around 10 a.m.

He then snatched up a banknote that was among the mementos and walked off with his friend toward Canal Street, cursing up a storm in apparent anger over the unprovoked slayings that authorities say were committed by vagrant Randy Santos, 24.

The man who grabbed the money returned about 15 minutes later,  clutching a miniature bottle of vodka instead.

After speaking aloud in front of the memorial, he opened the bottle, poured some of the liquor on the ground and took a sip.

He repeated the actions, raising a toast before he drank, then poured out what was remained in the bottle, which he placed amid the objects before storming off.