Bitcoin SegWit Explained: How Segregated Witness Optimizes Transactions
Understand how Bitcoin SegWit works, why it was activated, and how Segregated Witness reduces fees and fixes transaction malleability for all users.
Uvin Vindula — IAMUVIN
Published 2026-04-09
Bitcoin SegWit Explained: Segregated Witness Complete Guide
Segregated Witness, commonly known as SegWit, was activated on the Bitcoin network on August 24, 2017. It remains one of the most important protocol upgrades in Bitcoin's history, solving critical issues with transaction malleability, increasing effective block capacity, and paving the way for the Lightning Network and subsequent upgrades like Taproot.
The Problem SegWit Solved
Before SegWit, Bitcoin had two major issues:
Transaction Malleability
In Bitcoin's original design, the transaction ID (txid) was calculated from the entire transaction data, including the signature (witness) data. The problem was that signatures could be modified by third parties without invalidating them — a quirk of the ECDSA algorithm. This meant a transaction's ID could change before it was confirmed, breaking any systems that relied on tracking unconfirmed transactions by their ID.
This was more than a theoretical issue. Transaction malleability prevented the development of reliable payment channel networks (like Lightning) because these systems need to reference unconfirmed transactions by their ID.
Block Size Limitations
Bitcoin's original 1MB block size limit constrained the network to approximately 3-7 transactions per second. As adoption grew, this led to congestion, high fees, and slow confirmations. The community was deeply divided on how to scale — a conflict known as the "block size war."
How SegWit Works
SegWit's solution was elegantly simple: separate ("segregate") the signature data ("witness") from the transaction data.
The Witness Data
In a traditional Bitcoin transaction, the signature data sits inside the transaction input alongside the spending script. SegWit moves this data to a separate structure called the witness, which is attached to the transaction but not included in the transaction ID calculation.
New Transaction ID Calculation
With the witness data separated, the transaction ID is now calculated only from the non-witness data. This means modifying the signature no longer changes the txid, completely fixing the malleability issue. A new identifier called the wtxid (witness transaction ID) includes the witness data for complete identification.
Block Weight System
SegWit replaced the simple 1MB block size limit with a block weight system:
- Non-witness data: counted at 4 weight units per byte
- Witness data: counted at 1 weight unit per byte
- Maximum block weight: 4,000,000 weight units (4 million vbytes)
This effectively increases the block capacity to approximately 2-2.3 MB for typical transactions, without changing the block size limit — a clever compromise in the scaling debate.
SegWit Address Types
SegWit introduced new address formats:
P2SH-SegWit (Nested SegWit)
Addresses starting with "3". These wrap SegWit transactions inside P2SH for backward compatibility. This was the first widely-adopted SegWit format because it worked with wallets that didn't yet support native SegWit.
Native SegWit (Bech32)
Addresses starting with "bc1q". These are the most efficient SegWit format, offering the lowest fees and best error detection through the Bech32 encoding. If your wallet supports it, always use native SegWit for the lowest transaction fees.
Taproot (Bech32m)
Addresses starting with "bc1p". Built on top of SegWit, Taproot represents the latest evolution with Schnorr signatures and MAST capabilities.
Benefits of Using SegWit
| Benefit | Impact |
|---|---|
| Lower fees | 30-40% reduction compared to legacy transactions |
| Fixed malleability | Enables Lightning Network and other Layer 2 protocols |
| Increased capacity | ~2-2.3 MB effective block size |
| Script versioning | Easier future upgrades (like Taproot) |
| Better error detection | Bech32 addresses catch more typos |
SegWit Adoption Statistics
As of 2026, SegWit adoption has reached over 80% of all Bitcoin transactions. Most major exchanges, wallets, and services support native SegWit, and many have made it the default address format. This widespread adoption has significantly reduced average transaction fees for the entire network.
How to Use SegWit
For Sri Lankan Bitcoin users, switching to SegWit is straightforward:
- Check your wallet: Most modern wallets (Sparrow, Blue Wallet, Exodus, Trust Wallet) default to SegWit addresses.
- Look for bc1q addresses: If your receive address starts with "bc1q" or "bc1p", you're already using SegWit.
- Create a new wallet if needed: If your wallet only generates addresses starting with "1", consider upgrading.
- Transfer your funds: Send Bitcoin from your legacy address to your new SegWit address.
Visit our tools page for recommended SegWit-compatible wallets and our learning center for detailed setup guides.
SegWit's Legacy
SegWit's greatest achievement may be the upgrades it enabled. By introducing script versioning, SegWit created a clean path for future improvements. The Taproot upgrade (SegWit version 1) built directly on this foundation. Future proposals like OP_CTV and APO will also use SegWit's versioning system, ensuring Bitcoin can continue to evolve without contentious hard forks.
Disclaimer: This article is for educational purposes only and does not constitute financial advice. Always do your own research before making any cryptocurrency decisions. The CBSL has not authorized cryptocurrency as legal tender in Sri Lanka.

By Uvin Vindula — IAMUVIN
Sri Lanka's leading Bitcoin educator. Author of "The Rise of Bitcoin".
Learn more →Related Articles
The Bitcoin Brief: LK
Weekly Bitcoin insights, market analysis, and Sri Lanka crypto news. Join 1,000+ readers.
Unsubscribe anytime · Educational content only