Energy security is a multidimensional and multifaceted concept, therefore defining it is a complex problem. It requires the consideration of a wide set of factors from the fields of economics, geology, ecology and geopolitics, all of which have an influence on energy security or the lack thereof. The article focuses on natural gas, which is a very specific fuel in the European context. It is the most “politicized” source of energy, as a consequence of its growing importance as a transition fuel in the energy transformation process. In order to identify dependencies between variables on the gas market and analyze their impact on it (in particular on underground storage), the authors chose a set of variables and built a Bayesian network. The network is an effective and flexible tool that allows analysis of the relationships between the variables that build them and model their values based on evidence. The article presents two stages of work with the Bayesian network. In the first one, a network was built based on historical data. It shows the relationships between the variables as well as the probability of the value ranges of individual variables. A huge advantage of the presented Bayesian network is that it can be used to model various scenarios on the gas market. Moreover, the ability to make statistical inferences for all its nodes represents a valuable additional feature. Several examples of such inferences are presented in the second stage of the analysis, examining the impact of consumption variability on the level of inventory in underground gas storage facilities, the impact of having an LNG terminal and the share of natural gas in electricity production on the storage capacity of a given country. The use of tools such as Bayesian networks allows us to better discover the interrelationships between variables influencing the energy market, analyze them, and estimate the impact on energy security of distinct scenarios described with specific metrics. A simple example of such a metric, i.e., the minimum level of gas storage at the end of the winter season, as well as its analysis and modeling using a relatively simple Bayesian network, is presented in this article.