Edge detection is in the forefront of image processing for object detection, it is crucial to have a good understanding of edge detection algorithms. Sobel which is a popular edge detection algorithm is considered in this work. There exists a function, edge.m which is in the image toolbox. In the edge function, the Sobel method uses the derivative approximation to find edges. Therefore, it returns edges at those points where the gradient of the considered image is maximum. The Sobel operator performs a 2-D spatial gradient measurement on images. It uses a pair of horizontal and vertical gradient matrices whose dimensions are 3×3 for edge detection operations. It will also demonstrate how to build a Sobel detector function of 5 ×5 dimension in matlab to find edges.