Andrea Ranocchia’s late winner earned Hull another crucial home win in the fight to preserve their Premier League status and heaped more pressure on the West Ham manager Slaven Bilic.

The Italian defender Ranocchia, signed on loan from Internazionale in January, headed home in the 85th minute to secure a 2-1 win. Andrew Robertson’s strike after the break had cancelled out West Ham striker Andy Carroll’s landmark opener.

This victory was their fourth in five unbeaten league games at home under their head coach Marco Silva and lifted them level on points with their relegation rivals Swansea, who play Middlesbrough on Sunday, while West Ham slumped to a fourth straight defeat.

Bilic said: “The only way you can stop the speculation is if you win games or get a point or climb up the table. After four defeats of course I can expect even more speculation, but as I said I wasn’t worried before and I’m not worried now. I’m doing my job. I’m very motivated and very positive.”

The visit of West Ham had been billed as the return of winger Robert Snodgrass, sold to the Londoners for £10.2m in January, but the Scot made little impact and was withdrawn in the second half.

Snodgrass was booed every time he was on the ball, but almost silenced the Tigers fans in the 13th minute when he headed Sofiane Feghouli’s bouncing right-wing cross straight at goalkeeper Eldin Jakupovic.

Neither side had mustered an effort on goal until that point, but West Ham took the lead with their next chance five minutes later. Hull’s captain Curtis Davies misjudged his headed clearance from Aaron Cresswell’s excellent cross and, as the ball dropped invitingly for Carroll six yards out, the big No9 kept his composure to side-foot home on the volley for his 50th Premier League goal and seventh of the season.

Jakupovic denied West Ham a second soon after when he turned away Manuel Lanzini’s dipping, low shot from outside the area. Hull tried to rally and only some desperate defending denied Oumar Niasse a shooting chance in the area after Sam Clucas’s clever back-heel, but the home side failed to trouble Darren Randolph at all in the first period.

An out-of-sorts Davies was withdrawn for the winger Kamil Grosicki at the interval as Silva looked to inject some vigour into his side and not for the first time this season his tactical switch paid dividends.

Hull’s best move of the match saw Lazar Markovic link well with Grosicki and the latter slipped in a marauding Robertson to run on into the area and bury a low left-footed shot into the bottom corner for a 53rd-minute equaliser.

Hull City’s Andrew Robertson celebrates scoring. Photograph: Ed Sykes/Reuters

Carroll’s thumping header was then instinctively saved by Jakupovic, but the Tigers had stirred at last and all of a sudden West Ham looked rattled. Hull threatened again when Alfred N’Diaye’s right-footed effort hit a post and Grosicki fired the rebound wide.

Both sides were chasing a winner. Feghouli headed Lanzini’s cross wide and then spurned another chance when firing off target, but it was Hull who cashed in on their momentum.

Silva sent on a midfielder, Markus Henriksen, and Shaun Maloney for Abel Hernández and N’Diaye with 10 minutes left and three minutes later his side snatched the lead. Grosicki curled in a corner from the left and Ranocchia rose 10 yards out at the near post and directed a fine header beyond Randolph into the opposite corner.

Carroll and his team-mate Sam Byram were both off target in the closing stages as West Ham chased an equaliser, but Bilic’s side fell short and are now just six points above the drop zone.

Marcos Silva was delighted. “It’s not a secret, it’s the work,” the Portuguese manager said. “We all work, our staff, our players, the supporters as well because nobody wins alone. It’s important and they’re very good numbers and give us all more confidence.”