Blog

Posts written in February 2026.

  • Published on
    -
    3 min read

    5 Years of Investing

    I can still remember the very first stock I invested in. It was the Vanguard S&P 500 Accumulating index fund (VUAG), led by some other random and very bad stock picks. In fact, it has been 5 years to the day. How time flies!

    If I could tell my novice investor self to do just one thing, that would be to start my investment journey by sticking to a single index fund and not act foolhardy in the quest to try and make a load of money by picking individual stocks.

    It's quite easy to have a false sense of confidence investing in a passive fund, like the S&P 500 (where you aren't doing anything complicated), when you see you're in the green making a profit. The human condition is wired to always want more. We're never happy with what we have and convince ourselves that we could accelerate growth by picking overhyped assets just because everyone else seems to be getting rich quickly. The moment we step outside the safety of a simple fund to chase bigger returns, we end up fighting our own psychology.

    Instead of trying to figure out how to get rich quickly, focus on how to avoid losing money. Warren Buffett's two famous rules of investing are: 1) Don't lose money, and 2) Don't forget rule number one.

    Trying to pick individual winning companies is incredibly difficult, and the odds are stacked against the average investor unless you really do your due diligence and ask the right questions.

    The Bessembinder Study looked at 26,000 companies between 1926 and 2016, where researcher Hendrik Bessembinder found that just over 4% (about 1,000 companies) delivered all of the stock market's returns. It is much simpler to own the racetrack, like an index fund, instead of trying to pick the winning horse.

    Even though I started out investing in the S&P 500 that solely tracks top American companies, you might want to consider a global index that embraces both developing and emerging markets. Thanks to rising US tariffs and protectionist trade policies, the rest of the world is actively reducing its reliance on America, making global investing incredibly timely. Today, around 85% of global trade flows through alternative channels, and the US's share of world trade has hit its lowest point since 2014.

    You may think having a single index is quite boring. A boring portfolio can end up being the most fruitful one! If I take my wife's investment portfolio, which I manage, it simply consists of three funds, and year-to-date she has already made around a 4.8% return. This might not sound like much, but when you consider the S&P 500 returns 8-10% annually, she is already hitting half those returns and we're only 2 months into this year.

    Interestingly, a Fidelity study from 2013 looked at which investors had the best-performing portfolios over a decade. The top performers had one thing in common: they were dead. They couldn't tinker, panic, or second-guess themselves. A "nice" morbid fact to put your investment mindset into perspective.

    Even though my portfolio is bigger in monetary and position terms, it hasn't reached the heights my wife's has this year so far, as I am more bullish on specific sectors and companies from looking at the financials. I may not be making much of a return at this moment in time, but if everything goes to plan, the returns should outpace my wife's. I enjoy the investing process and looking for potential. In whatever decisions I make, in the back of my mind I always remember what Eugene Fama famously said:

    Money is like soap. The more you handle it, the less you'll have.

    So, I am always treading carefully by doing my due diligence and investing with conviction!

    The overarching lesson I've learnt is that complexity is not a prerequisite for success. If you are just starting out, do yourself a massive favour and begin with the absolute basics. Investing regularly into a single, globally diversified index fund, regardless of whether the market is up or down, is more than enough to get the compounding snowball rolling while you learn the ropes.

    You can always expand your horizons later, branching into individual stocks or specific sectors only once you have built a solid foundation of knowledge and genuinely enjoy the process of analysing the financials. Until then, there is absolutely no shame in keeping things boring. In fact, for the vast majority of people, a simple, hands-off approach isn't just fine—it is the optimal strategy for building long-term wealth. Start simple, stay consistent, and let the market do the heavy lifting.

  • An image doesn't just consist of pixels. It is a container full of additional information and structural inefficiencies hidden from the naked eye. When you capture a photo with a smartphone or a professional DSLR, the resulting file is almost always significantly larger than it needs to be for the web.

    This "image bloat" generally falls into two categories: Informational and Structural.

    • Informational: EXIF (Exchangeable Image File Format) data is metadata stored within the image header that includes GPS coordinates, camera serial numbers, and date-time stamps. While useful for photographers, this data adds unnecessary kilobytes to every upload and can even pose a privacy risk.
    • Structural: This is mainly down to resolution overkill, where modern cameras capture images at 12MP or higher - perfect for a billboard print, but massive for a website. But other reasons could be due to Sensor Noise where the digital sensor captures random variations in colour that the human eye can't distinguish, but the file's compression algorithm works overtime to preserve.

    The Hidden Cost of Raw Uploads

    When it comes to the process of uploading images through an online, we are often causing unnecessary strain on the end-user's connection as well as our own servers. By forcing a browser to transmit raw, unoptimised files, we create a high probability of failure through multiple, redundant requests.

    Every time a user on a unstable connection attempts to push a 10MB high-resolution photo, they are essentially gambling with the connection's stability. If that connection blips at 95%, the request fails, and the server is left with garbage data it can't use. The user is forced to start the entire process over again. This cycle doesn't just waste bandwidth; it inflates server CPU usage as it struggles to manage timed-out threads and increases the physical storage costs for data that the user never actually intended to be so large.

    Real-World Scenario

    I encountered this exact bottleneck while developing a valuation form. In this scenario, users were required to upload multiple high-quality photos of their assets for appraisal. On paper, this sounds simple. However, in the real world, users aren't always sitting on high-speed fibre-optic broadband. They are often out in the field, where the connection could be unstable.

    What was required is the ability for the image to be compressed on the users device before the upload process even starts. I found a JavaScript library that was worth a try: browser-image-compression.

    How The Client-Side Compression Works

    This library works by leveraging the browser's internal Canvas API and Web Workers to perform a digital reconstruction of the image. When a file is processed, it is drawn onto an invisible canvas at a set resolution, which instantly strips away all bloat like EXIF metadata and GPS coordinates. Then re-encodes the pixels using lossy compression algorithms to discard high-frequency noise.

    This entire magical process happens on a background thread (Web Worker), the image is crunched down to a fraction of its original size without freezing the user interface, ensuring the new lean file is ready for a faster upload.

    Results

    The difference in upload performance was night and day. Images that were originally 8–10MB were now being compressed to approximately 900KB. It is worth noting that the compression could have been even more aggressive; however, we capped the maximum size at 1MB, as we felt that was the perfect "sweet spot" for maintaining high visual quality in this scenario.

    By hitting that 900KB mark, we effectively reduced the data transfer requirements by 90%!

    Demo

    To see these performance gains in action, I have put together a live demo where you can upload your own high-resolution photos and see the real-time reduction in "image bloat" without any loss in visual quality.

    Browser Image Compression - Demo

    Conclusion

    Implementing client-side compression isn't just a nice-to-have feature. It is a fundamental shift in how we handle user data and server resources. By moving the processing to the user's device, we achieve three major wins:

    • Reliability: Small files don't just upload faster; they succeed more often. By reducing an 8MB file to 900KB, you remove the timeout risk that plagues users on unstable connections.
    • Privacy by Default: Because the library reconstructs the image on a canvas, sensitive EXIF data and GPS coordinates are stripped before they ever reach your cloud storage. This reduces your liability and protects your users.
    • Infrastructure Savings: The backend no longer needs to spend expensive CPU cycles stripping metadata or resizing massive blobs. You save on bandwidth, processing power, and long-term storage costs.
Support

If you've found anything on this blog useful, you can buy me a coffee. It's certainly not necessary but much appreciated!

Buy Me A Coffee