In this answer I want to discuss the habit of distinguishing between 'initial value problem' and 'boundary value problem'. This discussion will be for the context of classical mechanics. I expect the reasoning will generalize to other fields of physics.
I will first discuss the initial/boundary subject, and subsequently how that discussion ties in with the Euler-Lagrange equation.
This answer is inspired by a blog post by Chad Orzel.
(At the end of this answer I quote the key remark by Chad Orzel.)
For completeness I start with the trivial case of an object moving at a uniform velocity, with one spatial degree of freedom:
Initial value problem:
A train is moving at $x/t$ kilometers per hour. How long does it take to reach a destination $x$ kilometers away?
Boundary value problem:
A train travels to a train station $x$ kilometers away. At what velocity must the train travel such that it arrives at the destination after $t$ hours?
When the problem is stated as an initial value problem we solve it by way of extrapolation, when the problem is stated as a boundary value problem we solve it by way of interpolation. The '-polation' of 'extrapolation' and 'interpolation' is related to the verb 'to polish'; you are obtaining a smooth result.
The difference between stating a problem as an initial value problem or a boundary value problem is that the order of operations to solve the problem is different, that is all.
For the next level up we allow a known uniform acceleration, and two spatial degrees of freedom.
You have a cannon that can shoot projectiles. Firing of a projectile occurs from a level surface, so that the projectile impacting the ground is at the same height as when it was fired. Assume standard Earth gravity.
Initial value problem:
Given a nozzle velocity, and angle of the barrel with respect to the horizontal, what is the horizontal distance that the projectile will travel, and what will be the duration of the flight?
Boundary value problem:
What must the horizontal velocity component be, and what must the vertical velocity component be, such that the horizontal distance traveled is x meters, and the duration of the flight is t seconds?
The point is:
Just as in the simpler case of uniform velocity: the only difference between stating the problem as an initial value problem or a boundary value problem is the order of operations needed to solve the problem.
Distinction between 'initial value problem' and 'boundary value problem' boils down to distinction between extrapolation and interpolation, and that distinction is moot.
The common factor of interpolation and extrapolation is that you ensure continuity, smoothness. It's the condition of maintaining continuity that makes it work.
In particular: for a differential equation distinction between interpolation and extrapolation is moot. (In both cases it hinges on making sure continuity is satisfied.)
The process of deriving the Euler-Lagrange equation
The process of deriving the Euler-Lagrange equation removes all elements that are unnecessary.
I repeat with different words:
In the course of deriving the Euler-Lagrange equation various elements are removed. The elements that are removed are superfluous as far as solving the physics problem is concerned.
(From here on I will abbreviate Euler-Lagrange equation to: EL-eq.)
When you start deriving the EL-eq. the boundary conditions are treated as variables in the sense that the boundary conditions are not stated as numerical values; the boundary conditions are left unspecified. By allowing the boundary conditions to be variables you are obtaining a very general result. What you obtain is not tied to any specific boundary conditions, and what that does is that application of boundary conditions is deferred.
In the course of deriving the EL-eq. you introduce a way of representing variation. (Most often a symbol such as $\epsilon$ is used to manipulate the variation.) In the final stage of deriving the EL-eq. the variation is eliminated. In a sense the variation is like a catalyst; it is involved in the derivation, but it is not present in the final result.
What is also eliminated: at the start of deriving the EL-eq. an integration is specified. In the final stage that integration is eliminated. You cannot not eliminate that integration. The only way to derive the EL-eq. at all is to follow through, and eliminate the integration.
We have that the Euler-Lagrange equation is a differential equation.
As we know: a differential equation is a mathematical entity that is inherently describing a local property. By contrast: integration is evaluation of a global property.
The fact that the Euler-Lagrange equation is a differential equation is the very thing that makes it so powerful.
The derivation of the Euler-Lagrange equation is set up in such a way that the boundary conditions are treated as variables. What that does is that application of the boundary conditions is deferred.
The power of the Euler-Lagrange equation is that it is a differential equation; distinction between boundary value problem and initial value problem is moot.
An october 2021 answer by me with discussion of Hamilton's stationary action
About that blog post by Chad Orzel:
Chad Orzel raises the question:
is [...] teleological interpretation of least-action principles an accurate reflection of actual physics?
Chad Orzel points out:
[...] it amounts to specifying a starting position and an ending position and being amazed that the path is determined, but if instead you specified a starting position and starting velocity, the path is equally inevitable, but somehow that feels less magical.