Almost all products and items that exist on the market today have a unique code or identifier associated with them. We call this special identifier a barcode. Barcode detection is very common and is a necessity today as it makes our job easier. You can simply scan the code and easily get all the product information. Barcodes are still the prevalent machine-readable encoding mechanism for most products and services. At this stage of development, the barcode was quite common. Most items and products present in the household now have their own unique barcodes. They can be scanned and easily get all the necessary information, such as price, product details and description. There are even various apps available to scan the barcode through our phones. This is due to the high-quality pixel cameras that are present in all iPhones, android devices, or windows phones. Today, a wide range of portable devices for general use, such as mobile phones, come with an optical imaging system. Providing these general-purpose portable devices with barcode recognition is a cost-effective alternative to conventional barcode scanners. The equipment is available to billions of people. Combined with new services, this could revolutionize day-to-day shopping, including checking in-store prices, getting product information, accessing product reviews, finding similar products and services, and comparing prices locally. Detecting barcodes in images captured by general-purpose portable devices is particularly challenging due to the limitations of the integrated imaging system and on-device processing capabilities. These devices often have lower quality lens systems and lower resolution imaging circuits when compared to dedicated digital cameras. The optical system is often not designed for shooting close to the lens, resulting in out-of-focus and poorly lit images with rich colors. These limitations often mean that using conventional threshold detection methods cannot create a suitable template for barcode recognition. These limitations need to be considered in an algorithm that can invariably be implemented on a wide variety of portable devices. Barcode reading must be resistant to harsh conditions such as blur, noise, low resolution or low-quality camera lenses, which are very common. Surprisingly, even the most advanced barcode reading algorithms fail when some of these factors come into play. In this article, we present a new approach to barcode image detection. Our algorithm is specially designed to recognize barcodes when an image may be of low resolution, low quality, or suffer from significant blur, defocus, uneven lighting, noise and color saturation. The algorithm is accurate, fast, scalable and can be easily configured to find a valid result within a time constraint. Our algorithm is useful for real-time barcode recognition on handheld devices with limited processing capabilities such as mobile phones.