I want to place a webcam between 6m (20ft) and 12m (40ft) from my subject and have a capture width of 3m (10ft). If I understand the formula, with an estimated sensor width of 8.46mm (1/3"), I need a variable focal length of 16.92mm-33.84mm (2x zoom).

All my searching has not produced a webcam which can do that (without digital software based zoom). So, I plan to try to custom "build" my own solution by taking the plastic casing off my webcam and attaching the sensor inside to a SLR lens. Here are my questions:

  1. Does the brand/quality/kind of lens I use for this, matter? The number of 16-34mm lenses available is staggering (with an equally staggering price range).

  2. How far from the lens should I put the sensor?

  3. Other than for protection, do I need some kind of special casing around the webcam/lens connection?

5 Answers 5


I have been working on a project which also requires, more or less, a webcam with HD quality (something like 720p) and an optical zoom lens. There are such things for sale ... but they are industrial-strength, and industrial-priced, such as pan-tilt-zoom cameras for high-end videoconferencing equipment. And, of course, there are the commercial cameras that the TV broadcasters use. There aren't any such things in the consumer marketplace.

I found one guy who took apart a Sony camcorder and bolted its zoom lens to a standard webcam. He has a video of the process here: http://hackaday.com/2012/03/01/a-zoom-lens-for-your-webcam/ I did about the same thing: I also took the zoom lens out of an old Sony camcorder, and literally bolted it onto the circuit board of a Sony PlayStation "Eye" webcam (good electronics for $40), and "FrankenCam" works fairly well. The image is decent but washed-out. I need to work on aperture control. And I may need a better IR filter.

I found another guy who will sell you a Sony Playstation Eye webcam, installed in a case with a standard lens mount, here: http://peauproductions.com He also offers a low-pass filter that may help me with my image quality. I may try that if I can't get decent results on my own.

But I still think that we both could instead find an off-the-shelf camcorder, or digital camera, with a 'real-time' image feed. Many cameras and camcorders will support an external "AV feed", but all the ones I've seen, and bought, send out very poor video, usually broadcast-TV quality. I'm still looking for a good camera that will put out real-time HD video. For example, I have high hopes for the new Samsung Galaxy Camera, an Android tablet that thinks its a high-quality camera, which I just started to research.

Update, August 2014: Here's the status of my project, after a year of window-shopping and experimenting. My "FrankenCam" described above is working fine, in terms of the original requirements, and with the re-installation of the IR filter from the Playstation Eye camera. But I had two new problems: (1) the only Playstation webcam driver for Windows doesn't work with my 64-bit software stack, and (2) I couldn't reliably get a fast shutter speed, which the OP may not need, but I needed it: my project is video-recognition, in real-time, of race cars on a racetrack, to support a real-time scoring system, and of course I need a very short exposure time to capture a fast-moving race car. So I bought some more hardware: a Panasonic HCV-250 camcorder which puts out 1080p/60fps into a standard HDMI cable, and an AverMedia ExtremeCap U3 Capture Box which converts the HDMI signal into USB3 for my laptop. I looked at a lot of other cameras and HDMI interface boxes, and bought, tried, failed, and returned several. I still don't understand why a $20 webcam can put out a hi-def video signal over USB but a high-quality camcorder cannot ... but that's certainly another question, and off-topic here.

Hope this helps.


In theory, there should be no problem. Just put your webcam sensor in the same distance as is the one in your DSLR. You must also cover the connection so no light other than from the lens can reach the sensor.

Maybe some extension tubes will help you if you find them in proper length.

The only issues I see are:

  • Setting up Aperture. You must have older lens with aperture ring since the new ones are operated from body. Canon's new lens have opened aperture as default, Nikon's have it closed.
  • Lens MFT. Using such small sensor demands good optics. Since your sensor will capture center of your lens where they are sharpest, this may not be much of the problem.

If you make it, please post some results here. This DIY project looks interesting :)


I have made 2 adapters which enable a webcam to be used with a 35mm camera lens. The first enables the use of M42 screw-fit lenses, the second enables the use of Canon Bayonet fit lenses. The construction of each is similar, however the Canon fit unit is more complicated owing to the mount details. Therefore I will detail the M42 screw fit only. I am assuming that your webcam has a lens that can be removed by unscrewing. Firstly do a web search for "Webcam Astrophotography". This will give you a background of using a webcam with a telescope and the eyepiece adapter used. Next do another web search for "Camera Mounts and Registers". This details the distance between the SLR camera lens mounting face and the film plane in the camera. For M42 screw-fit lenses this distance is 45.46mm, though if you have other lenses in mind this dimension will differ. This means that the lens rear mounting face must be 45.46mm from the webcam sensor. Purchase a webcam to telescope eyepiece adapter. You now have to make an adapter which has a 1¼" hole at one end to accept the eyepiece adapter and the other end to accept an M42 camera mounting ring such that the distance from this mounting ring to the webcam sensor is exactly 45.46mm. Note that you may have to reduce the length of the eyepiece adapter to achieve this. If all goes well you should now have your webcam, a webcam/eyepiece adapter, an adapter to connect the webcam/eyepiece adapter and an M42 lesns. So remove the webcam lens and assemble thebits and pieces together, plug in the webcam USB cable and away you go. Lenses may be purchased very cheaply from between £5 and £10 sterling from camera fairs as also an old non-working SLR camera with an M42 lens mounting ring for spares, again for £5 sterling or less. So there you have it. Good luck with finding the parts. Choose good lenses. There is a huge stock of these obsolete lenses around so you should have no difficulty in finding a quality one to suit you requirements. Hywel Davies

  • I accidentally destroyed the shutter of a Minolta or something SLR. Since these things don't make sense to repair (the camera is $10 in working condition, and spare parts are often cannibalized anyway) I just tore the shutter out, and glued a webcam with its lens removed, roughly where the film plane was. Some electrical tape and cardboard to fix the light leaks - and there, a "normal" lens was suddenly a very long tele lens, because of the extreme crop factor of a webcam sensor vs 135 film. :-) Feb 28, 2020 at 9:07

You will likely run into issues due to the extremely small size of the sensor and the much larger sensor that an SLR lens is designed for. In theory, you might be able to move it closer to focal point of the lens if the lens' design allows, but I'm not sure if it would even be able to focus.

You really probably either want a webcam that includes a built in optical zoom (not sure if such a thing exists) or an actual camera that supports use as a video capture device (which could be plugged in to the computer and used in place of a webcam.) I imagine you could find either a DSLR or simple point and shoot that would support this functionality and likely cheaper than the cost of buying a DSLR lens.

  • I've looked for both of your suggestions, neither one exists that I can find. There are hacky suggestions for capture w/ a non-webcam but nothing reliable. May 26, 2013 at 21:47
  • 1
    @just.another.programmer I know Canon DSLRs support a live feed of video via the EOS Utility and it appears that software can be used to make that output show up as a video capture device to Windows. Additionally, a quick google for Optical Zoom Webcam shows multiple results that appear to meet your needs.
    – AJ Henderson
    May 26, 2013 at 22:16

What is your budget?

One approach is to get/buy/rent a DSLR that can provide a "live view" video feed. Then just use the appropriate tethering software. For my Canon 50D, which is a 5 year old camera, the standard Canon "EOS utility" will take the video feed on both Windows and Mac computers.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.