Does a higher hashrate strengthen Bitcoin network security?

In the blockchain world, proof-of-work is the dominant protocol mechanism that determines the consensus of the ledger. The hashrate, a measure of the computational power directed toward securing a blockchain through proof-of-work consensus, is a fundamental measure of preventing various attacks. This study tests the causal relationship between the hashrate and the security outcome of the Bitcoin block-chain. We use vector error correction modeling to analyze the endogenous relationships between the hashrate, Bitcoin price, and transaction fee, revealing the need for an additional variable to achieve our aim. Employing a measure summarizing the growth of demand factors in the Bitcoin ecosystem indicates that hashrate fluctuations significantly influence security level changes. This result underscores the importance of the hashrate in ensuring the security of the Bitcoin blockchain.


Introduction
One of the key features of the Bitcoin network is its proof-of-work consensus mechanism, which requires a significant amount of computational power to solve cryptographic puzzles. 1 The Bitcoin network generates a randomly selected target hash value.Bitcoin "miners" compete for the right to add the subsequent block in the blockchain and earn the compensation of guessing possible hash values equal to or less than the target value.The hashrate is simply the number of guesses of the hash value per second across all Bitcoin miners.A higher hashrate means that more computational power is being directed toward securing the network, making it more resistant to attacks from malicious actors.Our paper is devoted to empirically examining this security mechanism.
Computer scientists are constantly finding new methods of attacking blockchains.Saad et al. (2020) provide a systematic review of different types of attacks, yet controversy remains concerning the definition of attacks.Our research highlights the hashrate's role in ensuring blockchain security with proof-of-work protocol.Hence, our interest is in attacks associated with peer-to-peer architecture in establishing a consensus on which transactions to validate.Among such attack types of interest, the most famous is the "51% attack, " also called a "majority attack." If a single Bitcoin miner or group of miners working in concert could obtain a simple majority of the computational power on a blockchain, the miner(s) could manipulate information on the blockchain.This concern is valid, as instances of 51% attacks have been frequently detected throughout different blockchains, including "Bitcoin Gold" and "Litecoin Cash" (Lee and Kim 2020;Shanaev et al. 2020).Bitcoin is often highlighted for its vulnerability to 51% attacks due to the high block generation time variance (Bissias and Levine 2020;Bazzanella and Gangemi 2023).Budish (2022) discusses two subtypes of 51% attacks, namely, double-spending and sabotage, arguing that a double-spending attack is more likely to occur.Many studies of the 51% attack focus on the double spending attack subtype (Aponte-Novoa et al. 2021).Other blockchain attacks include "eclipse attacks" (Heilman et al. 2015) and "selfish mining" (Eyal and Sirer 2018).Another is the "Sybil attack, " which is usually implemented to execute other attacks, such as double spending (Zhang and Lee 2019).Some of the listed attacks can increase the uncertainty of transaction confirmations and reduce miners' potential rewards and the incentive to compete in solving hash values.Prevention from attacks is connected to decentralization, which is the spirit of permissionless blockchain.Securing rewards helps small miners survive in the industry, and decentralization disrupts the will of malicious miners.
Even though technological countermeasures to blockchain attacks have been suggested, the most fundamental measure preventing the system from attacks is the hashrate.More precisely, the proof-of-work protocol is designed to incentivize and increase miners' participation in the process, thereby increasing the total hashrate and making it more expensive to conduct attacks.This approach is especially effective against a 51% attack, where an attacker must control more than 50% of the network's computational power to manipulate the network.As the hashrate of the network increases, the cost of carrying out such an attack also increases, making the network more secure.
This study seeks to uncover the causal relationship between the hashrate and the security outcome within the Bitcoin network.The proof-of-work protocol is designed so that hashrate supports the network security.While prior research, such as Ciaian et al. (2021), has used hashrate to measure Bitcoin security, the strength and significance of the relationship remain uncertain.As frequently modeled in theoretical studies (Easley et al. 2019), a hashrate level may exist that works as a threshold determining the viability of the blockchain system.In that case, if the hashrate level is above the viability threshold, the impact of hashrate fluctuations on the security can become negligible.Various economic approaches have been used to examine blockchains through different dimensions,2 and our empirical investigation will be an interesting contribution to the literature on blockchain economics.
Achieving our objective is difficult because the security level is an unobservable variable.Therefore, we need to use different factors related to the demand side of the Bitcoin blockchain, which may allow us to see users' responses on the demand side.A natural starting point is to use the Bitcoin price and the Bitcoin transaction fee because they are the variables that can increase in response to strengthened security.Nonetheless, our econometric results and analyses in section "Endogenous relationship within the system" fail to verify or deny the causal relationship between the hashrate and the security level.Thus, we can conclude that the prices of Bitcoin and the Bitcoin transaction fee are not appropriate variables to test the relationship between the hashrate and level of security.Therefore, in section "Hashrate and the blockchain demand", we compute the first principal component of four factors related to blockchain (or cryptocurrency) users, which is a proxy for blockchain demand growth.Theoretically, four factors are influenced by blockchain security but are not directly related to the hashrate in any other paths.We use the constructed measure to confirm that hashrate fluctuations affect network security levels.
Our discussion on relationships among variables within the Bitcoin network indicates a need for another approach to reach this study's goal.Nevertheless, we expect that the discussion in section "Endogenous relationship within the system" will be helpful to researchers.Due to the complex interactions within the Bitcoin system, Kubal and Kristoufek (2022) use instrumental variables estimation.We also consider the vector error correction model (VECM) for the analyses because it can capture long-run comovements among variables (Sun et al. 2023).Using VECM allows us to incorporate feedback effects among Bitcoin variables both in the short and long run.Our analyses suggest interpretations based on consistent findings from some recent works.
The remainder of this paper is organized as follows.Section "Data description" describes the sample data for our analyses, and section "Endogenous relationship within the system" discusses the endogenous relationship among the hashrate, Bitcoin price, and transaction fee within the system based on the VECM model.Section "Hashrate and the blockchain demand" explains the hashrate and the blockchain demand by analyzing the Bitcoin network's active addresses, transactions, transfers, and wallets.

Data description
Our sample dataset spans from January 1, 2017, to January 5, 2023, covering a recent period for robust analyses.The data on blockchains and cryptocurrency markets are usually recorded in Coordinated Universal Time.Daily hashrate data is originally from Blockchain.com, retrieved from Nasdaq Data Link, and measured in terahashes (trillion hashes) per second.For the Bitcoin price, we use index data in United States dollars made by Coinmarketcap, and the data are obtained through Yahoo!Finance.Since Bitcoin is traded 24 h a day, a rational measure for a daily Bitcoin price is the arithmetic mean of open and closing prices.Transaction fee data is from Blockchair; unlike Blockchain.com,Blockchair provides daily median data as well as daily average data.We use the daily median transaction fee data to avoid outlier issues.A zero fee is the lower bound for the fee level, whereas there is no upper bound because some non-strategic decision-makers can bid an irrationally high fee level, causing outlier issues.The unit of the median transaction fee value is Satoshi.In the VECM, we use logarithmized data of the three variables. 3We do not call them logarithmic data in section "Endogenous relationship within the system" for convenience.Data of the three logarithmic variables are cointegrated in order 1.
There are four demand factors (network factors) suggested by Liu and Tsyvinski (2021): the number of active addresses, the number of transactions, the number of transfers (also called payments), and the number of wallets.Data for the first three variables are from Coin Metrics.The data on the number of wallets we download from the Nasdaq Data Link are data on the number of wallets provided by Blockchain.com.The variable we employ in our empirical analysis is the growth rate rather than the raw data.Although various businesses provide different kinds of Bitcoin wallets, we believe that it will not undermine the results of our study.4

Endogenous relationship within the system
We use VECM to investigate the endogenous relationship among the three logarithmized variables: hashrate, Bitcoin price, and transaction fee.The Johansen (1991) test result demonstrates a single cointegrating relationship.Using the result, we write the vector error correction system as follows: where Z t = Hashrate t−1 − 0.7489Price t−1 − 1.5583Price t−1 .The superscript of each coefficient denotes the label of the response variable, while the subscript of each coefficient indicates the label of the corresponding variable.are speeds of adjustment that can capture how fast the variable can converge to the long-run equilibrium, and e t are the error terms.We set the lag length in Eq. ( 1) at L = 14 .This decision is originally from a theoretical consideration rather than an empirical one because a Bitcoin mining adjustment occurs approximately every two weeks.The adjustment mechanism of Bitcoin will be explained later.Although using a short lag length is parsimonious, it can also be dangerous.When lagged variables are insufficient, e H t , e P t , and e F t can be correlated with their lagged variables, which causes endogeneity in the VECM equations.Therefore, a long lag length is also required in the empirical sense.
We expect that the price and fee's positive response to the rise in hashrate will be revealed, signaling the Bitcoin security level's positive response to the rise in hashrate. (1) Indicators associated with on-chain activities, including the hashrate, can affect Bitcoin price dynamics and off-chain activities and sentiments (Kukacka and Kristoufek 2023).
The price can reflect a cryptocurrency's valuation, which can depend on the security level of the corresponding blockchain.The transaction fee can also be an essential factor as the hashrate influences it via the level of security.When the security level is strengthened, agents will be more incentivized to remit Bitcoin to another agent's wallet through the Bitcoin network (Kim et al. 2023).When more users try to settle their transactions, congestion occurs, raising the transaction fee (Huberman et al. 2021).Table 1 presents the estimation results.
Figure 1 displays impulse response functions from the hashrate, showing that the hashrate does not significantly impact price but weakly impacts fees.We expect that a hashrate increase will lead to higher security, inducing greater participation by users and ultimately raising the transaction fees.This is the "security path" that we want to identify; however, we obtain an unexpected result.Namely, although the response after 7 or 8 days is positive, the hashrate generally negatively influences the fee.This finding conflicts with our initial prediction that an increase in the hashrate causes a fee increase; however, this result does not preclude the possibility that a higher hashrate strengthens network security and encourages more users.A different path-which may be more direct-from the hashrate to the fee other than the "security path" can exist, and that path may dominate the causal relationship.
Another likely path is when an increase in the hashrate reduces the fee, which would be possible if some mechanism leads to a higher hashrate from a tighter transaction capacity constraint in the Bitcoin network.Findings from recent research mentioned later support the existence of two such mechanisms.
The first mechanism is related to the mining difficulty of the cryptographic puzzle that miners try to solve.Assuming a consistent level of mining difficulty, when miners invest more computational efforts in the system, the total hashrate increases, and the generation speed of a single block will be faster.Similarly, under a constant mining difficulty, when miners invest less effort, the total hashrate will be lower, and the block generation will be slower.To ensure that the interval between two successive block generations stays around T = 10 minutes, the protocol within the Bitcoin blockchain automatically controls the mining difficulty, representing Bitcoin's mining difficulty adjustment.The mining difficulty is adjusted every 2,016 blocks, which responds slowly to real-time situations.Furthermore, the adjustment is based on the information from the past 2,016 blocks (Noda et al. 2022).
When the hashrate increases sharply in a short period owing to a positive shock but the adjustment is still a long way off, the time interval between blocks will fall to less than 10 min.This situation results in a larger capacity to confirm more transactions in an equivalent time interval.Each Bitcoin user will find it easier to confirm one's transaction at this relaxed capacity constraint, leading to a lower transaction fee bid.Interestingly, the case turns the other way when the adjustment occurs.When the adjustment to limit the capacity comes, a high hashrate may no longer characterize the situation, and the capacity can be heavily limited.This theory may explain why the coefficient estimates of the hashrate with small lags are all negative in the fee equation, whereas the hashrate variables with significant lags are often positive.The "slow and backward-looking adjustment" theory can help understand the "higher (lower) hashrate, lower (higher) fee" puzzle, but there is another hypothesis that can explain the puzzle even in the long run.As a criticism against the traditional models where the degree of competition in the Bitcoin mining industry does not influence the supply of transaction capacity, Lehar and Parlour (2022) show that a miner with high hashing occupancy can exercise its market power, strategically controlling the transaction validations.They find that miners intentionally leave blank spaces in generated blocks and do not always prioritize transactions with higher fees attached.This theory is consistent with Shao and Rajapaksa (2023), who also find that miners leave room in the blocks to increase their revenues.If less (more) hashing power is associated with higher (lower) mining concentration, the theory of "strategic miners" can account for the phenomenon of a higher hashrate reducing the fee miners earn.Many shocks in the mining industry are local events.Lehar and Parlour (2022) give an example of the 2021 coal mine disaster in Xinjiang, China.A coal mine flooded, We analyze the endogenous relationships within the Bitcoin ecosystem through a vector error correction model for the hashrate, price, and fee.ECT denotes an error correction term.Inside the parentheses are standard errors.*, **, and *** indicate statistical significance at the 10%, 5%, and 1% level, respectively and the Xinjiang region suffered a power outage, leading to the shutdown of regional Bitcoin miners.This event gave higher hashing occupancies to the miners operating in the other regions, while dropping total hashing power for several consecutive days (Makarov and Schoar 2022).The miners' strategic behaviors can be another explanation for why a higher hashrate accompanies an increase in the fee.Notably, a hashrate shock has no impact on the price of Bitcoin.Pagnotta (2022) argues that increasing the hashrate raises the blockchain security level, increasing the Bitcoin price.A simplistic view of this unexpected result would be that the price level depends on factors other than the blockchain's security level.Price may be heavily driven by factors related to users' network activity (Liu and Tsyvinski 2021) or attention (Goczek and Skliarov 2019;Koch and Dimpfl 2023).
Another interpretation, based on economic principles, is that a price rise attributed to strengthened security on the blockchain will ironically undermine its security.As Budish (2022) emphasizes, the decision of a miner to be dishonest is a matter of cost and benefit.Higher security can raise the price, but the attackers will find attacks more lucrative as Bitcoin increases in value.The higher chance of attacks will negatively influence security, offsetting the previous rise in the security level.This situation explains why the security change owing to the hashrate change has no significant impact on the price.If this interpretation is accurate, using the Bitcoin price to analyze the security level is limited.
Figure 2 shows that a positive price shock causes positive impacts on both the hashrate and the fee.It is clear why a higher price leads to a higher hashrate; the price surge means an improvement in profitability.On the contrary, it is unclear why the price shock raises the fee (even significantly).Kim et al. (2023) advance a model where a single user denoted by i decides to request its transaction be added to the Bitcoin network according to the following equation: V > a i E[w i ] + pγ i .Here, E[w i ] is the user i 's expected waiting time in the mempool, and a i is a parameter denoting i 's subjective cost of a unit waiting time.γ i is the fee that i attaches to the potential Fig. 1 Impulse response from total hashrate in Bitcoin.Notes: The three panels of this figure represent the functions of impulse response from the hashrate on the hashrate, price, and fee, respectively transaction, and p is the price of a unit of Bitcoin.Thus, the total cost from confirma- tion delay, a i E[w i ] , plus the market value of the fee bid, pγ i , should not exceed the expected transactional benefit, V .Accordingly, the price surge should raise the hurdle of user participation, lowering the fee by mitigating user competition.
The unexpected result of a positive price shock raising the fee may be due to a confounding factor-Bitcoin's popularity might have raised both investors' buying and users' transaction demands.Another highly likely interpretation is that V in the model above may be a function of p .When the Bitcoin price increases, the market value of the transacted Bitcoins can be higher.Then, users will find the confirmation of a single transaction more valuable; thus, the value of V can rise.The last impulse analysis is the impulse response from the network transaction fee shown in Fig. 3.The VECM estimation result shows that a positive fee shock does not significantly impact the hashrate and the price.Since the block reward occupies most of the total mining reward, the miners may not be actively responsive to the fluctuations in the fee.
The VECM analysis and interpretation implemented in this section are organized visually in Fig. 4. Solid lines in the figure represent directions of impact found through VECM.For each solid line, we attach a reason for the corresponding impact.Dashed lines represent the "security path" through which the hashrate boosts the security level and eventually raises the price and fee.The densely dotted line represents the effect the fee would have on the hashrate, as suggested by theory but was absent in the VECM results.Lastly, a sparsely dotted line starting from the Bitcoin price and pointing to security indicates the possibility that an increase in price harms the security.Complex interactions exist between the three variables used in the model.We conclude that the price and fee are unsuitable variables for identifying the hashrate's impact on network security.The panels suggest that the price is determined independently of the hashrate and fee.The influence of the hashrate on the fee is "contaminated" by different paths; thus, we need a better variable dependent on the network security but not related to the hashrate through a path other than the "security path." The analysis in this section involves the Bitcoin hashrate, price, and transaction fee.Since the cryptocurrency mining technology is evolving toward producing more hashes with the same amount of electricity (Gundaboina et al. 2022), the total hashrate is affected by the electricity cost of hashing, implying that unit mining cost should be included in the analysis.Despite the need, electricity costs differ by region; thus, we find it challenging to construct a suitable measure for the unit mining cost.We exclude Fig. 4 Analysis of the vector error correction model results.Notes: Solid lines are directions of impacts revealed by VECM.Dashed lines represent the "security path" by which hashrate increases the security level, raising the price and fee.The densely dotted line represents an effect of fee on hashrate, which can be supported by theory but are absent in the VECM results.Lastly, a sparsely dotted line starting from the bitcoin price and pointing to security indicates a hypothetical chance that an increase in price harms security the cost associated with electricity from the analysis.Furthermore, we do not consider implemented soft forks, such as SegWit, possibly related to electricity consumption (Schinckus et al. 2022).

Hashrate and the blockchain demand
Principal component analysis (PCA) can reduce the number of dimensions by transforming the original variables.Following Liu and Tsyvinski (2021), we compute the first principal component of the growth of four demand factors.The four factors are growth rates of the number of "active addresses, " "transactions, " "transfers, " and "wallets" in the Bitcoin network.Liu and Tsyvinski's measure covers various activities of blockchain users, making it a better alternative to Google searches (Nasir et al. 2019;Ibikunle et al. 2020) or trading volume in cryptocurrency exchange (Marmora 2022).We use linear interpolation when missing values occur in the wallet count data.There is also a limitation in interpreting the results of PCA.We identify the first component as a proxy for the demand growth in blockchain users.This proxy is an I(0) process, as plotted in Fig. 5.As most trades of major cryptocurrencies, such as Bitcoin, are currently being executed on centralized exchanges (Aspris et al. 2021), some distance exists between the computed demand growth proxy and speculative demand for cryptocurrency.The demand growth proxy mainly reflects the activities done by payments or remittances. 5e build a simple linear regression model as follows: where θ is the coefficient on hashrate growth and µ is an intercept parameter.We use hashrate growth data rather than the hashrate per se because the computed demand growth variable is an I(0) process.Testing the coefficient in Eq. ( 2) with the traditional ordinary least squares (OLS) method is subject to inconsistency problems arising from serial correlation.We apply the Newey-West (1987) estimator to test the coefficients' significance with OLS estimates.It is one of the HAC (heteroskedasticity-and autocorrelation-consistent) estimators used to estimate covariance matrix when data violate (2) Demand Growtht = µ + θ�Hashrate t , Fig. 5 The first principal component of the growth of four Bitcoin blockchain demand factors.Notes: This is the first principal component computed from PCA with growths of four Bitcoin blockchain demand factors.We call this measure "demand growth proxy." This is a stationary (I(0)) process only significant coefficient was the one on the regressor with no lag, we cannot discern between hashrate growth's impact on demand growth and demand growth's impact on hashrate growth; however, coefficients with lagged regressors are notably tested to be significant.The results of the two models show that the system hashrate positively affects blockchain users' demand.The results indicate that the hashrate movement matters greatly for security.One may counterargue that the users' positive responses toward a higher hashrate growth are not the outcome of security improvement; however, there is no other way in which the hashrate can affect users' demand for blockchain uses.The "hashrate" is designed to sustain the security of a blockchain.It is reasonable to believe that rational users know and respond to the blockchain's security situation.

Conclusion
This study aims to empirically identify the hashrate's impact on a blockchain's security level.We find complex relationships between variables in the Bitcoin ecosystem through the VECM for the Bitcoin hashrate, transaction fee, and price.Instead of using the price and fee as Bitcoin demand growth measures, we use a measure that summarizes the growth of some blockchain demand factors.This measure depends on the hashrate change, showing a strong linear relationship.Furthermore, blockchain users recognize the change in the network's security level caused by the change in the hashrate.
We alert designers of blockchain systems of the importance of the hashrate in ensuring the security of the blockchain with proof-of-work consensus protocol, contributing to the sustainability of financial innovations.Additionally, ongoing research on endogenous relationships within the Bitcoin ecosystem will highly benefit from our discussion in section "Endogenous relationship within the system." Our empirical analysis only focuses on the Bitcoin system; however, many permissionless blockchains exist with proof-of-work consensus protocols, such as Litecoin and Bitcoin Cash.This limited focus is the principal limitation of our study.The four factors mentioned above regarding cryptocurrency users are highly related to Bitcoin (Liu and Tsyvinski 2021); thus, our analysis in section "Hashrate and the blockchain demand" might be unsuitable for some other blockchains.Since Ethereum is another popular blockchain, the four factors might be highly related to the Ethereum; however, Ethereum is a blockchain currently adopting a proof-of-stake protocol.

Fig. 2
Fig. 2 Impulse response from bitcoin price.Notes: The three panels of this figure represent the functions of impulse response from the price on the hashrate, price, and fee, respectively

Fig. 3
Fig. 3 Impulse response from transaction fee in the Bitcoin network.Notes: The three panels of this figure represent the functions of impulse response from the transaction fee on the hashrate, price, and fee, respectively

Table 1
VECM estimation results