Hikvision Still Image

Hi guys,

Im wondering if anyone here can help me out, if gone through multiple threads and cant find an answer that works. What im trying to do is, add a card on the HA dash which grabs a still image from my Hikvision Camera. I’ve figured out the correct url to get a still image, however im unable to add it to the dash.

Any suggestions? I’ve tried Stream component and failed with getting it to work.

Use a picture-entity card.

Rather than a still image, I have a live view. You could do still if you wanted…

camera setup code:

camera:
  - platform: generic
    still_image_url: "rtsp://192.168.0.101:554/ISAPI/Streaming/channels/101/picture"
    stream_source: "rtsp://admin:[email protected]:554"
    name: Driveway

lovelace code:

type: picture-entity
show_state: false
camera_image: camera.driveway
entity: camera.driveway
camera_view: live

I just tried this code, im not getting no errors however no image or video is being loaded. the url provided is definately correct as ive got the same IP as the one youve provided and ive changed my login details saved, restarted server still showing blank. Do i need to add any addons or make changes anywhere else for this to work?

No, that should work as-is

shabz did you resolve this? I’ve got an identical problem here:/

I struggled with a HikVision camera for a while: stream worked great but still image not at all. Other non-HikVision cameras worked first time. What I found is that, while the still image worked fine typed into the browser address, it didn’t work for the still_image_url unless I added username and password. The still image doesn’t accept username:password@ in the URL. And while they aren’t necessary when typing the URL in the browser address, they are necessary when HA asks for them. The camera knows it’s not me, I guess. Here’s the only configuration that worked for me

- platform: generic
  name: <name>
  still_image_url: http://<ipaddress>/ISAPI/Streaming/Channels/2/picture
  stream_source: rtsp://<user>:<password>@<ipaddress>/Streaming/Channels/101/
  authentication: digest
  username: <user>
  password: <password>
3 Likes

Thanks for this. I can confirm this combo works for both stream and still image URL, so it can be used to take snapshots also. :slight_smile:

Thanks Dave for you suggestion,
Just wanted to add my experience with HikVision Cameras and NVR:

  1. stream_source uses NVR IP, with a dedicated “display only” user and password after RSTP://
  2. still_image_url must use IPs of Cameras, so User and Password are the Camera Admin ones!

It’s not good, from a security point of view, but I could not find any other solution, to get the still image!
In the end I decided to have live stream in my dashboard (not still images), to avoid security issues!

All my attempts to get the still image via the NVR (and not via Cameras) gave no result, unluckly!
This is the respose i have:

<ResponseStatus xmlns="http://www.hikvision.com/ver20/XMLSchema" version="1.0">
<requestURL>/ISAPI/Streaming/channels/101/picture</requestURL>
<statusCode>6</statusCode>
<statusString>Invalid XML Content</statusString>
<subStatusCode>badXmlContent</subStatusCode>
</ResponseStatus>

But if some of you had a suggetion, it would be welcome!
Hope it helps

Hello, I got the still image from hikvision camera using the following YAML:

  camera: 
  - platform: generic
    name: Câmera Cozinha
    still_image_url: "http://<IP>/ISAPI/Streaming/Channels/101/picture"
    stream_source: "rtsp://<USER>:<PASSW>@<IP>:<PORT>/ISAPI/Streaming/channels/101/"
    verify_ssl: false
    username: "<USER>"
    password: "<PASSW>"
    authentication: digest

The default scan interval is 10 sec. The authentication method can be set in camera configuration.

3 Likes

You can try this URL:
http:///ISAPI/ContentMgmt/StreamingProxy/channels/101/picture

It’s from here (page 344):

Is anyone also using hikvision intercoms? Seems they don’t have an still image… Only rtsp stream works

Just like to chime in and say that this was the solution for an Annke NVR, N48PAW, and that should be the same for about 10-15 other models.

Here is a documentation page about streaming ISAPI and channel IDs: rtsp://[:port]/ISAPI/Streaming/channels/ (hikvision.com)