
On one hand there was YHWH, to Whom Solomon's Temple in the south, as well as the northern sanctuaries of Dan and Bethel, would be solely and uncompromisingly dedicated. On the other hand there was the Phoenecian and Canaanite-native deity Baal, the storm god.
When King Ahab of the Omride dynasty took the Phoenecian princess Jezebel for his wife, the tide seemed to turn in Baal's favor:
(לא) וַיְהִי֙ הֲנָקֵ֣ל לֶכְתּ֔וֹ בְּחַטֹּ֖אות יָרָבְעָ֣ם בֶּן־נְבָ֑ט וַיִּקַּ֨ח אִשָּׁ֜ה אֶת־אִיזֶ֗בֶל בַּת־אֶתְבַּ֙עַל֙ מֶ֣לֶךְ צִידֹנִ֔ים וַיֵּ֙לֶךְ֙ וַֽיַּעֲבֹ֣ד אֶת־הַבַּ֔עַל וַיִּשְׁתַּ֖חוּ לֽוֹ׃ (לב) וַיָּ֥קֶם מִזְבֵּ֖חַ לַבָּ֑עַל בֵּ֣ית הַבַּ֔עַל אֲשֶׁ֥ר בָּנָ֖ה בְּשֹׁמְרֽוֹן׃
(31) Not content to follow the sins of Jeroboam son of Nebat, he [Ahab] took as wife Jezebel daughter of King Ethbaal of the Phoenicians, and he went and served Baal and worshiped him. (32) He erected an altar to Baal in the temple of Baal which he built in Samaria.

Her zealousness is one of the TaNaKh's most extreme instances of religious fanaticism. As a demonstration of its extent, here is how the narrator of Kings speaks favorably of Obadiah, one of her servants:
(ג) וַיִּקְרָ֣א אַחְאָ֔ב אֶל־עֹבַדְיָ֖הוּ אֲשֶׁ֣ר עַל־הַבָּ֑יִת וְעֹבַדְיָ֗הוּ הָיָ֥ה יָרֵ֛א אֶת־יְהוָ֖ה מְאֹֽד׃ (ד) וַיְהִי֙ בְּהַכְרִ֣ית אִיזֶ֔בֶל אֵ֖ת נְבִיאֵ֣י יְהוָ֑ה וַיִּקַּ֨ח עֹבַדְיָ֜הוּ מֵאָ֣ה נְבִאִ֗ים וַֽיַּחְבִּיאֵ֞ם חֲמִשִּׁ֥ים אִישׁ֙ בַּמְּעָרָ֔ה וְכִלְכְּלָ֖ם לֶ֥חֶם וָמָֽיִם׃
(3) Ahab had summoned Obadiah, the steward of the palace. Obadiah feared YHWH greatly. (4) And it had been, when Jezebel was killing off the prophets of YHWH, Obadiah had taken a hundred prophets and hidden them, fifty to a cave, and provided them with food and drink.

Note Jezebel's father's name: Ethbaal, or "with-Baal," a name similar in construct to Emmanuel, or "with-us-is-El" (Isaiah 7:14).
We don't learn anything more about Ethbaal from the TaNaKh, but there are two passages from the 1st century historical writings of Josephus which together fill in some details:
Now Menander mentions this drought in his account of the acts of Ethbaal, king of the Tyrians; where he says thus: "Under him there was a want of rain from the month Hyperberetmus till the month Hyperberetmus of the year following; but when he made supplications, there came great thunders."
והוא הומת בידי אחיו פלט אשר ירש את כסא מלכותו ומלך שמונה (חדשים, וימי חייו היו חמשים שנה. ואותו המית אתובעל11הוא אתבעל שבמקרא (מלכים א' טז, לא). כהן עשתורת ומלך תחתיו), וימי חייו היו ארבעים ושמנה שנה וימי מלכותו שלשים ושתים שנה
Pheles took the kingdom [of Tyre] and reigned but eight months, though he lived fifty years: he was slain by *Ithobalus, the priest of Astarte, who reigned thirty-two years, and lived sixty-eight years.
*Itobalus is Ethbaal as mentioned in 1 Kings 16.
We then get more from these passages of Josephus, in which he is relying on the work of Menander of Ephesus, a 2nd-century BCE historian who specialized in Ancient Phoenecia and the Kings of Tyre.
In the first of these passages we see Ethbaal acting as priest and offering supplications during a time of drought; and having his prayers answered. While it does not say which god he offered his supplications to, logic would dictate that it was Baal, known throughout the ancient near-east as the Storm-god of rain and fertility, also known as He-who-rides-on-the-clouds (an epithet which would later be commandeered by YHWH Himself; see for example, Deuteronomy 33:26.)
In the second of the two, we see that Ethbaal was, in fact, a priest even before he was a king! While its true that he served as a priest to a goddess named Astarte, she in turn was but a lesser goddess in a pantheon ruled by Baal, the supreme Phoenecian deity. Servants of Astarte were no less servants of Baal.
more about this can be found in Baal's entry in the Brittannica encyclopedia online: https://www.britannica.com/topic/Baal-ancient-deity


Here are the verses above, but with just a bit more context on the end:
(לא) וַיְהִי֙ הֲנָקֵ֣ל לֶכְתּ֔וֹ בְּחַטֹּ֖אות יָרָבְעָ֣ם בֶּן־נְבָ֑ט וַיִּקַּ֨ח אִשָּׁ֜ה אֶת־אִיזֶ֗בֶל בַּת־אֶתְבַּ֙עַל֙ מֶ֣לֶךְ צִידֹנִ֔ים וַיֵּ֙לֶךְ֙ וַֽיַּעֲבֹ֣ד אֶת־הַבַּ֔עַל וַיִּשְׁתַּ֖חוּ לֽוֹ׃ (לב) וַיָּ֥קֶם מִזְבֵּ֖חַ לַבָּ֑עַל בֵּ֣ית הַבַּ֔עַל אֲשֶׁ֥ר בָּנָ֖ה בְּשֹׁמְרֽוֹן׃ (לג) וַיַּ֥עַשׂ אַחְאָ֖ב אֶת־הָאֲשֵׁרָ֑ה וַיּ֨וֹסֶף אַחְאָ֜ב לַעֲשׂ֗וֹת לְהַכְעִיס֙ אֶת־יְהֹוָה֙ אֱלֹהֵ֣י יִשְׂרָאֵ֔ל מִכֹּ֨ל מַלְכֵ֣י יִשְׂרָאֵ֔ל אֲשֶׁ֥ר הָי֖וּ לְפָנָֽיו׃ (לד) בְּיָמָ֞יו בָּנָ֥ה חִיאֵ֛ל בֵּ֥ית הָאֱלִ֖י אֶת־יְרִיחֹ֑ה בַּאֲבִירָ֨ם בְּכֹר֜וֹ יִסְּדָ֗הּ ובשגיב [וּבִשְׂג֤וּב] צְעִירוֹ֙ הִצִּ֣יב דְּלָתֶ֔יהָ כִּדְבַ֣ר יְהוָ֔ה אֲשֶׁ֣ר דִּבֶּ֔ר בְּיַ֖ד יְהוֹשֻׁ֥עַ בִּן־נֽוּן׃ (ס) (א) וַיֹּאמֶר֩ אֵלִיָּ֨הוּ הַתִּשְׁבִּ֜י מִתֹּשָׁבֵ֣י גִלְעָד֮ אֶל־אַחְאָב֒ חַי־יְהוָ֞ה אֱלֹהֵ֤י יִשְׂרָאֵל֙ אֲשֶׁ֣ר עָמַ֣דְתִּי לְפָנָ֔יו אִם־יִהְיֶ֛ה הַשָּׁנִ֥ים הָאֵ֖לֶּה טַ֣ל וּמָטָ֑ר כִּ֖י אִם־לְפִ֥י דְבָרִֽי׃ (ס)
(31) Not content to follow the sins of Jeroboam son of Nebat, he took as wife Jezebel daughter of King Ethbaal of the Phoenicians, and he went and served Baal and worshiped him. (32) He erected an altar to Baal in the temple of Baal which he built in Samaria. (33) Ahab also made a sacred post. Ahab did more to vex the YHWH, the God of Israel, than all the kings of Israel who preceded him.
...
(1) Elijah the Tishbite, an inhabitant of Gilead, said to Ahab, “As YHWH lives, the god of Israel, before whom I stand! There will be no dew or rain except at my bidding.”
What follows is one of the most dramatic showdowns in the TaNaKh, which evokes ancient epics in which one people's hero issues a brazen and open challenge to the opposition.
Recall, for example, how the stage was set for David's take-down of Goliath:

(ד) וַיֵּצֵ֤א אִֽישׁ־הַבֵּנַ֙יִם֙ מִמַּחֲנ֣וֹת פְּלִשְׁתִּ֔ים גָּלְיָ֥ת שְׁמ֖וֹ מִגַּ֑ת גָּבְה֕וֹ שֵׁ֥שׁ אַמּ֖וֹת וָזָֽרֶת׃ (ה) וְכ֤וֹבַע נְחֹ֙שֶׁת֙ עַל־רֹאשׁ֔וֹ וְשִׁרְי֥וֹן קַשְׂקַשִּׂ֖ים ה֣וּא לָב֑וּשׁ וּמִשְׁקַל֙ הַשִּׁרְי֔וֹן חֲמֵשֶׁת־אֲלָפִ֥ים שְׁקָלִ֖ים נְחֹֽשֶֽׁת׃ (ו) וּמִצְחַ֥ת נְחֹ֖שֶׁת עַל־רַגְלָ֑יו וְכִיד֥וֹן נְחֹ֖שֶׁת בֵּ֥ין כְּתֵפָֽיו׃ (ז) וחץ [וְעֵ֣ץ] חֲנִית֗וֹ כִּמְנוֹר֙ אֹֽרְגִ֔ים וְלַהֶ֣בֶת חֲנִית֔וֹ שֵׁשׁ־מֵא֥וֹת שְׁקָלִ֖ים בַּרְזֶ֑ל וְנֹשֵׂ֥א הַצִּנָּ֖ה הֹלֵ֥ךְ לְפָנָֽיו׃ (ח) וַֽיַּעֲמֹ֗ד וַיִּקְרָא֙ אֶל־מַעַרְכֹ֣ת יִשְׂרָאֵ֔ל וַיֹּ֣אמֶר לָהֶ֔ם לָ֥מָּה תֵצְא֖וּ לַעֲרֹ֣ךְ מִלְחָמָ֑ה הֲל֧וֹא אָנֹכִ֣י הַפְּלִשְׁתִּ֗י וְאַתֶּם֙ עֲבָדִ֣ים לְשָׁא֔וּל בְּרוּ־לָכֶ֥ם אִ֖ישׁ וְיֵרֵ֥ד אֵלָֽי׃ (ט) אִם־יוּכַ֞ל לְהִלָּחֵ֤ם אִתִּי֙ וְהִכָּ֔נִי וְהָיִ֥ינוּ לָכֶ֖ם לַעֲבָדִ֑ים וְאִם־אֲנִ֤י אֽוּכַל־לוֹ֙ וְהִכִּיתִ֔יו וִהְיִ֤יתֶם לָ֙נוּ֙ לַעֲבָדִ֔ים וַעֲבַדְתֶּ֖ם אֹתָֽנוּ׃ (י) וַיֹּ֙אמֶר֙ הַפְּלִשְׁתִּ֔י אֲנִ֗י חֵרַ֛פְתִּי אֶת־מַעַרְכ֥וֹת יִשְׂרָאֵ֖ל הַיּ֣וֹם הַזֶּ֑ה תְּנוּ־לִ֣י אִ֔ישׁ וְנִֽלָּחֲמָ֖ה יָֽחַד׃
(4) A champion of the Philistine forces stepped forward; his name was Goliath of Gath, and he was six cubits and a span tall. (5) He had a bronze helmet on his head, and wore a breastplate of scale armor, a bronze breastplate weighing five thousand shekels. (6) He had bronze greaves on his legs, and a bronze javelin [slung] from his shoulders. (7) The shaft of his spear was like a weaver’s bar, and the iron head of his spear weighed six hundred shekels; and the shield-bearer marched in front of him.
(8) He stopped and called out to the ranks of Israel and he said to them:
“Why should you come out to engage in battle? I am the Philistine [champion], and you are Saul’s servants. Choose one of your men and let him come down against me! (9) If he bests me in combat and kills me, we will become your slaves; but if I best him and kill him, you shall be our slaves and serve us!” (10) And the Philistine ended, “I herewith defy the ranks of Israel. Get me a man and let’s fight it out!”

(יט) וְעַתָּ֗ה שְׁלַ֨ח קְבֹ֥ץ אֵלַ֛י אֶת־כָּל־יִשְׂרָאֵ֖ל אֶל־הַ֣ר הַכַּרְמֶ֑ל וְאֶת־נְבִיאֵ֨י הַבַּ֜עַל אַרְבַּ֧ע מֵא֣וֹת וַחֲמִשִּׁ֗ים וּנְבִיאֵ֤י הָֽאֲשֵׁרָה֙ אַרְבַּ֣ע מֵא֔וֹת אֹכְלֵ֖י שֻׁלְחַ֥ן אִיזָֽבֶל׃ (כ) וַיִּשְׁלַ֥ח אַחְאָ֖ב בְּכָל־בְּנֵ֣י יִשְׂרָאֵ֑ל וַיִּקְבֹּ֥ץ אֶת־הַנְּבִיאִ֖ים אֶל־הַ֥ר הַכַּרְמֶֽל׃ (כא) וַיִּגַּ֨שׁ אֵלִיָּ֜הוּ אֶל־כָּל־הָעָ֗ם וַיֹּ֙אמֶר֙ עַד־מָתַ֞י אַתֶּ֣ם פֹּסְחִים֮ עַל־שְׁתֵּ֣י הַסְּעִפִּים֒ אִם־יְהוָ֤ה הָֽאֱלֹהִים֙ לְכ֣וּ אַחֲרָ֔יו וְאִם־הַבַּ֖עַל לְכ֣וּ אַחֲרָ֑יו וְלֹֽא־עָנ֥וּ הָעָ֛ם אֹת֖וֹ דָּבָֽר׃ (כב) וַיֹּ֤אמֶר אֵלִיָּ֙הוּ֙ אֶל־הָעָ֔ם אֲנִ֞י נוֹתַ֧רְתִּי נָבִ֛יא לַיהוָ֖ה לְבַדִּ֑י וּנְבִיאֵ֣י הַבַּ֔עַל אַרְבַּע־מֵא֥וֹת וַחֲמִשִּׁ֖ים אִֽישׁ׃ (כג) וְיִתְּנוּ־לָ֜נוּ שְׁנַ֣יִם פָּרִ֗ים וְיִבְחֲר֣וּ לָהֶם֩ הַפָּ֨ר הָאֶחָ֜ד וִֽינַתְּחֻ֗הוּ וְיָשִׂ֙ימוּ֙ עַל־הָ֣עֵצִ֔ים וְאֵ֖שׁ לֹ֣א יָשִׂ֑ימוּ וַאֲנִ֞י אֶעֱשֶׂ֣ה ׀ אֶת־הַפָּ֣ר הָאֶחָ֗ד וְנָֽתַתִּי֙ עַל־הָ֣עֵצִ֔ים וְאֵ֖שׁ לֹ֥א אָשִֽׂים׃ (כד) וּקְרָאתֶ֞ם בְּשֵׁ֣ם אֱלֹֽהֵיכֶ֗ם וַֽאֲנִי֙ אֶקְרָ֣א בְשֵׁם־יְהוָ֔ה וְהָיָ֧ה הָאֱלֹהִ֛ים אֲשֶׁר־יַעֲנֶ֥ה בָאֵ֖שׁ ה֣וּא הָאֱלֹהִ֑ים וַיַּ֧עַן כָּל־הָעָ֛ם וַיֹּאמְר֖וּ ט֥וֹב הַדָּבָֽר׃ (כה) וַיֹּ֨אמֶר אֵלִיָּ֜הוּ לִנְבִיאֵ֣י הַבַּ֗עַל בַּחֲר֨וּ לָכֶ֜ם הַפָּ֤ר הָֽאֶחָד֙ וַעֲשׂ֣וּ רִאשֹׁנָ֔ה כִּ֥י אַתֶּ֖ם הָרַבִּ֑ים וְקִרְאוּ֙ בְּשֵׁ֣ם אֱלֹהֵיכֶ֔ם וְאֵ֖שׁ לֹ֥א תָשִֽׂימוּ׃
(19) [Elijah said to King Ahab] "Summon all Israel to join me at Mount Carmel, together with the four hundred and fifty prophets of Baal and the four hundred prophets of Asherah, who eat at Jezebel’s table!”
(20) Ahab sent orders to all the Israelites and gathered the prophets at Mount Carmel.
(21) Elijah approached all the people and said, “How long will you keep hopping between two opinions? If YHWH is God, follow Him!; and if Baal, follow him!”
But the people answered him not a word.
(22) And Elijah said to the people, “I am the only prophet of YHWH left, while the prophets of Baal are four hundred and fifty men! (23) Let two young bulls be given to us. Let them choose one bull, cut it up, and lay it on the wood, but let them not apply fire; I will prepare the other bull, and lay it on the wood, and will not apply fire. (24) You will then invoke your god by name, and I will invoke the LORD by name; and let us agree: the god who responds with fire, that one is God.” And all the people answered, “Very good!” (25) Elijah said to the prophets of Baal, “Choose one bull and prepare it first, for you are the majority; invoke your god by name, but apply no fire.”

(27) And it was at noon, that Elijah mocked them, saying, “Shout louder! After all, he is a god. But he may be in conversation, he may be detained, or he may be on a journey, or perhaps he is asleep and will wake up!”
(28) So they shouted louder, and gashed themselves with knives and spears, according to their practice, until the blood streamed over them.
(36) When it was time to present the meal offering, the prophet Elijah came forward and said:
“O YHWH, God of Abraham, Isaac, and Israel! Let it be known today that You are god in Israel and that I am Your servant, and that I have done all these things at Your bidding! (37) Answer me, O YHWH, answer me, that this people may know that You, O YHWH, are god; for You have turned their hearts backward!”
(38) Then fire from YHWH descended and consumed the burnt offering, the wood, the stones, and the earth; and it licked up the water that was in the trench.
(39) And all the people saw this, and flung themselves on their faces and cried out: “YHWH alone is the god, YHWH alone is the god!"

(40) Then Elijah said to them, “Seize the prophets of Baal, let not a single one of them get away!”
They seized them, and Elijah took them down to the Wadi Kishon and slaughtered them there.

All of this seems to have taken an enormous toll on Elijah, who flees all the way to Beersheva (!!!), and seems intent to starve himself due to a combination of fatigue and frustration. It seems that as long as Jezebel and Ahab reigns, he will be hunted, and the people will continuously be pulled back towards Baal. When God asks him why he's in Beersheva, we get a sense of the depth of his exhaustion in his response:
(ט) וַיָּבֹא־שָׁ֥ם אֶל־הַמְּעָרָ֖ה וַיָּ֣לֶן שָׁ֑ם וְהִנֵּ֤ה דְבַר־יְהוָה֙ אֵלָ֔יו וַיֹּ֣אמֶר ל֔וֹ מַה־לְּךָ֥ פֹ֖ה אֵלִיָּֽהוּ׃ (י) וַיֹּאמֶר֩ קַנֹּ֨א קִנֵּ֜אתִי לַיהוָ֣ה ׀ אֱלֹהֵ֣י צְבָא֗וֹת כִּֽי־עָזְב֤וּ בְרִֽיתְךָ֙ בְּנֵ֣י יִשְׂרָאֵ֔ל אֶת־מִזְבְּחֹתֶ֣יךָ הָרָ֔סוּ וְאֶת־נְבִיאֶ֖יךָ הָרְג֣וּ בֶחָ֑רֶב וָֽאִוָּתֵ֤ר אֲנִי֙ לְבַדִּ֔י וַיְבַקְשׁ֥וּ אֶת־נַפְשִׁ֖י לְקַחְתָּֽהּ׃
(9) There he went into a cave, and there he spent the night. And the word of YHWH came to him. He said to him, “Why are you here, Elijah?”
(10) He replied, “I am moved by zeal for YHWH, the God of Hosts, for the Israelites have forsaken Your covenant, torn down Your altars, and put Your prophets to the sword. I alone am left, and they are out to take my life.”

(16) Anoint Jehu son of Nimshi as king of Israel, and anoint Elisha son of Shaphat of Abel-meholah to succeed you as prophet. (17) Whoever escapes the sword of Hazael shall be slain by Jehu, and whoever escapes the sword of Jehu shall be slain by Elisha.

As fate, chance, or indomitable will (you decide) would have it, our god YHWH would win the day. As far as I know, there has not been a single person devoted to Baal in thousands of years, and Elijah is considered one of our greatest heroes of old, of whom we sing, invite to our celebrations, and anticipate his coming back to herald the next Davidic King.
Personally, as someone who believes that by virtue of being an Israelite I have a personal relationship with YHWH Whom I try to fear, to love, and constantly pester with my prayers daily, I cannot help but look back with pride on His having been able to overcome divine obstacles and ultimately wrest our devotion away from Baal.
But of course, the cost was high. And we have no way of knowing when our ancient heroes were truly doing His will, or when they either misunderstood, or maybe hastily reacted in a way that He never actually sanctioned.

Of course none of us can know the answer. We are conjecturing about the ancient near east, which compared to our world today, may as well have been a whole different universe! But I find that the thought-experiments that such questions evoke can oftentimes be deeply meaningful and worthwhile.

