We review recent results on O- and Mg-isotope compositions of refractory grains (corundum, hibonite) and calcium, aluminum-rich inclusions (CAIs) from unequilibrated ordinary and carbonaceous chondrites. We show that these refractory objects originated in the presence of nebular gas enriched in 16O to varying degrees relative to the standard mean ocean water value: the Δ17OSMOW value ranges from approximately −16‰ to −35‰, and recorded heterogeneous distribution of 26Al in their formation region: the inferred (26Al/27Al)0 ranges from approximately 6.5 × 10−5 to <2 × 10−6. There is no correlation between O- and Mg-isotope compositions of the refractory objects: 26Al-rich and 26Al-poor refractory objects have similar O-isotope compositions. We suggest that 26Al was injected into the 26Al-poor collapsing protosolar molecular cloud core, possibly by a wind from a neighboring massive star, and was later homogenized in the protoplanetary disk by radial mixing, possibly at the canonical value of 26Al/27Al ratio (approximately 5 × 10−5). The 26Al-rich and 26Al-poor refractory grains and inclusions represent different generations of refractory objects, which formed prior to and during the injection and homogenization of 26Al. Thus, the duration of formation of refractory grains and CAIs cannot be inferred from their 26Al-26Mg systematics, and the canonical (26Al/27Al)0 does not represent the initial abundance of 26Al in the solar system; instead, it may or may not represent the average abundance of 26Al in the fully formed disk. The latter depends on the formation time of CAIs with the canonical 26Al/27Al ratio relative to the timing of complete delivery of stellar 26Al to the solar system, and the degree of its subsequent homogenization in the disk. The injection of material containing 26Al resulted in no observable changes in O-isotope composition of the solar system. Instead, the variations in O-isotope compositions between individual CAIs indicate that O-isotope composition of the CAI-forming region varied, because of coexisting of 16O-rich and 16O-poor nebular reservoirs (gaseous and/or solid) at the birth of the solar system, or because of rapid changes in the O-isotope compositions of these reservoirs with time, e.g., due to CO self-shielding in the disk.